From 04ec3bec6322596e067078d846f240ebddfd2fc6 Mon Sep 17 00:00:00 2001 From: Haoqun Jiang Date: Wed, 13 Nov 2024 16:15:32 +0800 Subject: [PATCH] Revert "feat!: use `#/src` instead" This reverts commit 28b5aaf25049a4c6b5ce105a229ab89413923857. --- template/base/jsconfig.json | 4 ++-- template/base/package.json | 2 +- template/base/vite.config.js.ejs | 2 +- template/code/router/src/App.vue | 2 +- template/code/typescript-router/src/App.vue | 2 +- template/config/cypress-ct/cypress/support/component.js | 2 +- template/config/cypress-ct/cypress/support/component.ts | 2 +- template/tsconfig/base/tsconfig.app.json | 4 ++-- template/tsconfig/nightwatch-ct/tsconfig.app.json | 4 ++-- 9 files changed, 12 insertions(+), 12 deletions(-) diff --git a/template/base/jsconfig.json b/template/base/jsconfig.json index 4bd2b782..b5f03929 100644 --- a/template/base/jsconfig.json +++ b/template/base/jsconfig.json @@ -2,8 +2,8 @@ "compilerOptions": { "paths": { // TODO: no longer needed after TS 5.4 - "#/*": ["./*"], - // Deprecated, use `#/src` instead (configured in `package.json` `imports` field) + "#src/*": ["./src/*"], + // Deprecated, use `#src` instead (configured in `package.json` `imports` field) "@/*": ["./src/*"] } }, diff --git a/template/base/package.json b/template/base/package.json index d00f6e14..f711a567 100644 --- a/template/base/package.json +++ b/template/base/package.json @@ -2,7 +2,7 @@ "private": true, "type": "module", "imports": { - "#/*": "./*" + "#src/": "./src/" }, "scripts": { "dev": "vite", diff --git a/template/base/vite.config.js.ejs b/template/base/vite.config.js.ejs index b148800b..c5cd9d2f 100644 --- a/template/base/vite.config.js.ejs +++ b/template/base/vite.config.js.ejs @@ -14,7 +14,7 @@ export default defineConfig({ ], resolve: { alias: { - // Deprecated, use `#/src` instead (configured in `package.json` `imports` field) + // Deprecated, use `#src` instead (configured in `package.json` `imports` field) '@': fileURLToPath(new URL('./src', import.meta.url)) }, }, diff --git a/template/code/router/src/App.vue b/template/code/router/src/App.vue index 593fb9c3..719e4d99 100644 --- a/template/code/router/src/App.vue +++ b/template/code/router/src/App.vue @@ -5,7 +5,7 @@ import HelloWorld from './components/HelloWorld.vue'