rollup-plugin-requiretoimport
require 转 import插件
使用方法
npm i -D rollup-plugin-requiretoimport
import requireToImportPlugin from 'rollup-plugin-requiretoimport';
export default defineConfig({
plugins: [
requireToImportPlugin()
]
})
this is plugins for rollup to deal with dependence code turn require into import
JavaScript
require 转 import插件
npm i -D rollup-plugin-requiretoimport
import requireToImportPlugin from 'rollup-plugin-requiretoimport';
export default defineConfig({
plugins: [
requireToImportPlugin()
]
})