-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ea0ab5c
commit 168fb8f
Showing
13 changed files
with
179 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -61,7 +61,7 @@ typings/ | |
.next | ||
|
||
# app | ||
dist | ||
dist-* | ||
.vscode | ||
.swc | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"extends": "./tsconfig.json", | ||
"compilerOptions": { | ||
"outDir": "dist-cjs", | ||
"module": "commonjs", | ||
"rootDir": "src", | ||
"sourceMap": true, | ||
"declaration": true, | ||
"declarationMap": true | ||
}, | ||
"include": ["src"], | ||
"exclude": ["src/**/*.spec.ts"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"extends": "./tsconfig.json", | ||
"compilerOptions": { | ||
"outDir": "dist-esm", | ||
"module": "ES2015", | ||
"moduleResolution": "node", | ||
"rootDir": "src", | ||
"sourceMap": true, | ||
"declaration": true, | ||
"declarationMap": true | ||
}, | ||
"include": ["src"], | ||
"exclude": ["src/**/*.spec.ts"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,48 @@ | ||
{ | ||
"extends": "@tsconfig/node14/tsconfig.json", | ||
"ts-node": { | ||
"swc": true, | ||
"require": ["tsconfig-paths/register"], | ||
"compilerOptions": { | ||
// Sometimes projects (e.g. Nextjs) will want code to emit ESM but ts-node will not work with that. | ||
"module": "CommonJS" | ||
} | ||
}, | ||
"compilerOptions": { | ||
"rootDir": "src", | ||
"outDir": "dist", | ||
"module": "commonjs", | ||
"target": "es2016", | ||
"strict": true, | ||
"declaration": true, | ||
"declarationMap": true, | ||
"esModuleInterop": true | ||
// Make the compiler stricter, catch more errors | ||
"noImplicitReturns": true, | ||
"noFallthroughCasesInSwitch": true, | ||
"noUncheckedIndexedAccess": true, | ||
"noImplicitOverride": true, | ||
// We handle these with ESLint: | ||
// "noUnusedLocals": false, | ||
// "noUnusedParameters": false, | ||
|
||
// Output | ||
"importHelpers": true, | ||
|
||
// DX | ||
"incremental": true, | ||
"tsBuildInfoFile": "node_modules/.cache/.tsbuildinfo", | ||
"noErrorTruncation": true, | ||
"baseUrl": ".", | ||
"paths": { | ||
"~/*": ["./src/*"] | ||
}, | ||
|
||
// Transformer Plugins made possible by https://github.com/nonara/ts-patch | ||
"plugins": [ | ||
// https://github.com/LeDDGroup/typescript-transform-paths | ||
{ "transform": "typescript-transform-paths" }, | ||
{ "transform": "typescript-transform-paths", "afterDeclarations": true } | ||
] | ||
}, | ||
"include": ["src"], | ||
"exclude": ["src/**/*.spec.ts"] | ||
"include": ["src", "tests", "scripts", "jest.*"], | ||
// Prevent unwanted things like auto-import from built modules | ||
"exclude": ["dist-*"], | ||
"plugins": [ | ||
{ | ||
"name": "typescript-snapshots-plugin" | ||
} | ||
] | ||
} |
Oops, something went wrong.