enable-absolute-paths
v0.1.2
Published
Enable absolute paths in a TypeScript project
Downloads
10
Readme
enable-absolute-paths
Enable absolute paths in a TypeScript project
Import files with ~/
. Assumes a ./src
folder.
src/example.ts
-> ~/example
Usage
npx enable-absolute-paths@latest
vite
If using vite
, add this to your vite.config.ts
resolve: {
alias: {
'~': resolve(__dirname, 'src'),
},
},