Skip to content

Commit

Permalink
try: esm relative alias path
Browse files Browse the repository at this point in the history
  • Loading branch information
yb6b committed Mar 12, 2024
1 parent e2df836 commit eb34964
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
node_modules
dist
___*
src/.vitepress/cache
src/.vitepress/cache
*timestamp*
4 changes: 2 additions & 2 deletions src/.vitepress/config.mts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { defineConfig } from 'vitepress'
import { argv } from "node:process";
import path from "node:path"
import tailwind from "tailwindcss"
import autoprefixer from "autoprefixer"
import { fileURLToPath } from 'node:url'

const base = argv.at(-1) === 'yima' ? '/yima/' : '/'
console.log(base);
Expand Down Expand Up @@ -30,7 +30,7 @@ export default defineConfig({
},
resolve: {
alias: {
'@': path.resolve(__dirname, '../../components'),
'@': fileURLToPath(new URL("../../components", import.meta.url)),
}
}
},
Expand Down

0 comments on commit eb34964

Please sign in to comment.