Skip to content

Commit e97d7cc

Browse files
committed
chore: update unimport
1 parent 0321b82 commit e97d7cc

File tree

4 files changed

+26
-43
lines changed

4 files changed

+26
-43
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@
9696
"@rollup/pluginutils": "^4.2.1",
9797
"local-pkg": "^0.4.1",
9898
"magic-string": "^0.26.2",
99-
"unimport": "^0.3.0",
99+
"unimport": "^0.4.0",
100100
"unplugin": "^0.7.0"
101101
},
102102
"devDependencies": {

playground/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"@vitejs/plugin-vue": "^2.3.3",
1313
"@vue/compiler-sfc": "^3.2.37",
1414
"element-plus": "^2.2.6",
15-
"unplugin-vue-components": "^0.19.6",
15+
"unplugin-vue-components": "^0.20.0",
1616
"vite": "^2.9.12",
1717
"vite-plugin-inspect": "^0.5.0"
1818
}

pnpm-lock.yaml

Lines changed: 22 additions & 39 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/core/ctx.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ export function createContext(options: Options = {}, root = process.cwd()) {
4242
...(options.vueTemplate ? [vueTemplateAddon()] : []),
4343
resolversAddon(resolvers),
4444
{
45-
decleration(dts) {
45+
declaration(dts) {
4646
if (!dts.endsWith('\n'))
4747
dts += '\n'
4848
return `// Generated by 'unplugin-auto-import'\n${dts}`
@@ -63,7 +63,7 @@ export function createContext(options: Options = {}, root = process.cwd()) {
6363

6464
function generateDTS(file: string) {
6565
const dir = dirname(file)
66-
return unimport.generateTypeDecarations({
66+
return unimport.generateTypeDeclarations({
6767
resolvePath: (i) => {
6868
if (i.from.startsWith('.') || isAbsolute(i.from)) {
6969
const related = slash(relative(dir, i.from).replace(/\.ts$/, ''))

0 commit comments

Comments
 (0)