I am currently getting the below error when trying to use path mappings within the jsconfig.json
file inside of my .NET React App:
Here are the contents of the jsconfig.json
file:
{
"compilerOptions": {
"target": "ES6",
"baseUrl": ".",
"module": "commonjs",
"jsx": "react",
"paths": {
"@components/*": ["./src/app/components/*"]
}
},
"include": ["./src/**/*"],
"exclude": ["node_modules", "config", ".vscode"]
}
And here is the file structure of my app:
For now, I have just been trying for a components
path mapping, but as mentioned, I am getting the module not found error when trying to import a component on the homepage of my application.
Any suggestions?