Open Tanimodori opened 2 years ago
It would be nice to have this feature. But I suppose you can just use rollup-plugin-copy for that.
rollup-plugin-copy
doesn't support that feature either:
https://github.com/vladshcherbin/rollup-plugin-copy/issues/5
If I understand you right, it is actually possible.
For example if you have a .js file, just save it, then build-watch
will be triggered and files will be copied to destination folder as defined in vite config..
package.json:
"scripts": {
"dev": "vite",
"build": "vite build",
"build-watch": "vite build --watch --config ./vite.config.js",
},
Hope that I didn't misunderstand the problem. :)
rollup-plugin-copy
doesn't support that feature either:
Looks like a fork has been made to implements this: https://www.npmjs.com/package/@guanghechen/rollup-plugin-copy
Currently this plugin does not watch file changes on
vite build --watch
, thewatch
related code areserve
-only. It would be better to support watching file changes with watched build.