Skip to content

Commit

Permalink
Add absolute path
Browse files Browse the repository at this point in the history
  • Loading branch information
gaoooon committed May 11, 2024
1 parent a85ee1b commit 75c66eb
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@
"isolatedModules": true,
"noEmit": true,
"jsx": "react-jsx",

"paths": {
"@/*": ["./src/*"]
},
/* Linting */
"strict": true,
"noUnusedLocals": true,
Expand Down
4 changes: 4 additions & 0 deletions vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
import { defineConfig } from 'vite';
import react from '@vitejs/plugin-react';
import { resolve } from 'path';

// https://vitejs.dev/config/
export default defineConfig({
plugins: [react()],
cacheDir: './.vite',
resolve: {
alias: [{ find: '@', replacement: resolve(__dirname, 'src') }],
},
});

0 comments on commit 75c66eb

Please sign in to comment.