Socket
Socket
Sign inDemoInstall

copy-vite-plugin

Package Overview
Dependencies
2
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    copy-vite-plugin

> The most simple and easy-to-use vite copy plugin.


Version published
Weekly downloads
68
increased by134.48%
Maintainers
1
Install size
232 kB
Created
Weekly downloads
 

Readme

Source

copy-vite-plugin

The most simple and easy-to-use vite copy plugin.

use like copy-webpack-plugin

If you are migrating from webpack to vite and looking for an copy plugin, this plugin will be very suitable for you.

Compare the usage of copy-webpack-plugin and copy-vite-plugin:

// webpack.config.js
const CopyPlugin = require('copy-webpack-plugin')

module.exports = {
  plugins: [
    new CopyPlugin({
      patterns: [
        // copy dir
        { from: 'src/images', to: 'images' },
        // copy file
        { from: 'src/constants/info.json', to: 'info.json' }
      ]
    })
  ]
}
// vite.config.ts
import { copy } from 'copy-vite-plugin'

export default defineConfig({
  plugins: [
    copy({
      pattern: [
        // copy dir
        { from: 'src/images', to: 'images' },
        // copy file
        { from: 'src/constants/info.json', to: 'info.json' }
      ]
    })
  ]
})

Install

# npm
npm i copy-vite-plugin -D

# yarn
yarn add copy-vite-plugin -D

# pnpm
pnpm add copy-vite-plugin -D

Keywords

FAQs

Last updated on 17 Jan 2023

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc