A base TSConfig for working with Remix.
npm install @tsconfig/remixAdd the package to your "devDependencies":
``sh`
npm install --save-dev @tsconfig/remix
yarn add --dev @tsconfig/remix
Add to your tsconfig.json:
`json`
"extends": "@tsconfig/remix/tsconfig.json"
> NOTE: You may need to add "baseUrl": "." to your tsconfig.json to support proper file resolution.
---
The tsconfig.json:
`jsonc
{
"$schema": "https://www.schemastore.org/tsconfig",
"_version": "2.0.0",
"compilerOptions": {
"lib": ["dom", "dom.iterable", "es2019"],
"isolatedModules": true,
"esModuleInterop": true,
"jsx": "react-jsx",
"module": "esnext",
"moduleResolution": "bundler",
"resolveJsonModule": true,
"target": "es2019",
"strict": true,
"allowJs": true,
"baseUrl": ".",
"paths": {
"~/": ["./app/"]
},
// Remix takes care of building everything in remix build.
"noEmit": true
}
}
``
You can find the code here.