Skip to content

Commit

Permalink
docs: update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
zanminkian committed Dec 22, 2024
1 parent 8d82dae commit a95f33b
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 5 deletions.
6 changes: 3 additions & 3 deletions eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
import { Builder } from "fenge/eslint-config";

export default new Builder()
.enablePackagejson()
.enableJavascript()
.enableTypescript({
.enablePackageJson()
.enableJavaScript()
.enableTypeScript({
omit: ["@fenge/no-restricted-loops", "no-console"],
})
.toConfig();
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
"test": "pnpm -r test && pnpm style"
},
"devDependencies": {
"@changesets/cli": "2.27.10",
"fenge": "0.2.1",
"@changesets/cli": "2.27.11",
"fenge": "0.3.0",
"typescript": "5.7.2"
},
"packageManager": "[email protected]",
Expand Down
36 changes: 36 additions & 0 deletions packages/tscx/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,42 @@

A `tsc` wrapper with many convenient features. Bring the [nodemon](https://www.npmjs.com/package/nodemon) + JavaScript development experience to TypeScript.

## Why

Developing a backend application using TypeScript needs some other third-party library. It's tedious and hard to config 🤦‍♂️.

```json
{
"scripts": {
"clean": "rimraf dist",
"compile": "tsc -p tsconfig.build.json",
"copy-files": "copyfiles -u 1 src/**/*.njk dist",
"build": "npm run clean && npm run compile && npm run copy-files",
"dev": "NODE_ENV=local nodemon -w src -e ts --exec 'npm run build && node bootstrap.js'"
},
"devDependencies": {
"copyfiles": "2.4.1",
"nodemon": "3.1.0",
"rimraf": "5.0.5",
"typescript": "5.6.3"
}
}
```

Now you can simplify your `package.json` by using this library 😄.

```json
{
"scripts": {
"dev": "NODE_ENV=local tscx -rwc -p tsconfig.build.json -e bootstrap.js"
},
"devDependencies": {
"@rnm/tscx": "*",
"typescript": "5.6.3"
}
}
```

## Highlight

- Same usages as `tsc`.
Expand Down

0 comments on commit a95f33b

Please sign in to comment.