18 lines
456 B
JavaScript
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import autoImport from 'unplugin-auto-import/vite';
// 自动导入插件
// 配置完成之后使用ref reactive watch 等无须import 导入 ,可以直接使用
export default function createAutoImport() {
return autoImport({
imports: [
'vue',
'vue-router',
{
vuex: ['useStore'],
},
],
// 可以选择auto-import.d.ts生成的位置使用ts建议设置为'src/auto-import.d.ts'
dts: false,
});
}