This PR fixes alias configuration in the vite config and ts configuration files. This alllows us to import easily, consistency across codebase and vscode intellisense. There are two ways you may import files:
add a '@/' before the file and the configuration resolves them to ./src/*. For example, 'components' is a folder inside src. To import a file from 'components' folder, you may do this: import MyComponent from '@/components/ui/MyComponent
the folder name directly. For example, 'components' is a folder inside src. To import a file from 'components' folder, you may do this: import MyComponent from 'components/ui/MyComponent'
I'd advise to use the 2nd way of imports going forward so that if we use any 3rd party packages with imports that have '@' , it reduces confusion.
This PR also takes the fix from pending PR #27 by @believemanasseh which corrects the jest import for the test setup file.
This PR fixes alias configuration in the vite config and ts configuration files. This alllows us to import easily, consistency across codebase and vscode intellisense. There are two ways you may import files:
import MyComponent from '@/components/ui/MyComponent
import MyComponent from 'components/ui/MyComponent'
I'd advise to use the 2nd way of imports going forward so that if we use any 3rd party packages with imports that have '@' , it reduces confusion. This PR also takes the fix from pending PR #27 by @believemanasseh which corrects the jest import for the test setup file.