Skip to content

Commit

Permalink
update docs, add nodenext config
Browse files Browse the repository at this point in the history
  • Loading branch information
rosskevin committed Jan 22, 2025
1 parent 81be482 commit da28764
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 3 deletions.
12 changes: 9 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,26 @@ yarn install -D @alienfast/tsconfig

*This config requires TypeScript 5 or later.*

## Available configs

- `node`
- `nodenext` - extends `node` with changed `module` and `moduleResolution`
- `react` - for bundling
- `react-lib` - extends `react`, focused on library builds

## Usage

Example for a `node` package:

```json
{
"$schema": "https://json.schemastore.org/tsconfig",
"extends": "@alienfast/tsconfig/node.json",
"extends": "@alienfast/tsconfig/node.json",
"compilerOptions": {
"composite": true,
"outDir": "dist",
"rootDir": "src"
},
"include": ["src", "../../typings/**/*", "../../typings-local/**/*"],
"include": ["src", "typings"],
"exclude": ["node_modules", "dist"],
}
```
11 changes: 11 additions & 0 deletions nodenext.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"$schema": "https://json.schemastore.org/tsconfig",

"display": "NodeNext shared base.",

"extends": "./node.json",
"compilerOptions": {
"moduleResolution": "nodenext",
"module": "NodeNext"
}
}

0 comments on commit da28764

Please sign in to comment.