@checkdigit/typescript-config 9.1.0-PR.71-3ed3 → 9.1.0-PR.71-fee0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +21 -19
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -6,9 +6,9 @@ Copyright © 2021–2025 [Check Digit, LLC](https://checkdigit.com)
6
6
 
7
7
  ## Introduction
8
8
 
9
- This module contains the standard Check Digit Typescript configuration, along with our standard build tool `builder`.
9
+ This module contains the standard Check Digit TypeScript configuration, along with our standard build tool `builder`.
10
10
 
11
- ## Typescript Configuration
11
+ ## TypeScript Configuration
12
12
 
13
13
  - currently requires Node 22.11 or above.
14
14
  - emits `esnext`, with the default libraries, to avoid down-leveling. It is intended that application spec tests pick
@@ -19,7 +19,7 @@ This module contains the standard Check Digit Typescript configuration, along wi
19
19
 
20
20
  ## Builder
21
21
 
22
- `builder` is a command line tool that generates ESM modules from the Typescript source.
22
+ `builder` is a command line tool that generates ESM modules from the TypeScript source.
23
23
  It is intended to be used when publishing a package to NPM, or to bundle a package for deployment.
24
24
  It uses `tsc` for generating types, and `esbuild` for generating code.
25
25
 
@@ -42,19 +42,19 @@ dynamic `require`s by CommonJS submodules. This is not a problem for Node.js, bu
42
42
  ### Examples
43
43
 
44
44
  ```shell
45
- # build ESM .mjs files from Typescript source
45
+ # build ESM .mjs files from TypeScript source
46
46
  npx builder --type=module --outDir=build-esm
47
47
 
48
- # build single-file ESM .mjs bundle from Typescript source
48
+ # build single-file ESM .mjs bundle from TypeScript source
49
49
  npx builder --type=module --outDir=build-esm-bundle --entryPoint=index.ts --outFile=index.mjs
50
50
  ```
51
51
 
52
52
  ## Tests
53
53
 
54
- This module includes a number of integration-style tests, to ensure that a specific version of Typescript will interoperate
54
+ This module includes a number of integration-style tests,
55
+ to ensure that a specific version of TypeScript will interoperate
55
56
  with `builder`, in addition to libraries and frameworks used by Check Digit:
56
57
 
57
- - Jest and `ts-jest`
58
58
  - ESLint and `@typescript-eslint/eslint-plugin`
59
59
  - Built-in `node:test` runner
60
60
  - prettier
@@ -62,23 +62,25 @@ with `builder`, in addition to libraries and frameworks used by Check Digit:
62
62
  - esbuild
63
63
  - Wallaby.js (supports `node:test` by including `@swc-node/register` as a peer dependency)
64
64
 
65
- We do this to ensure that Typescript upgrades do not break these dependencies. New major versions of Typescript are not immediately
66
- supported by projects such as ts-jest, eslint, prettier, etc. Our policy is to wait until these projects fully support
67
- the new version of Typescript, and/or without emitting warnings during these tests, before publishing.
65
+ We do this to ensure that TypeScript upgrades do not break these dependencies.
66
+ New major versions of TypeScript are not immediately
67
+ supported by projects such as eslint, prettier, typescript-eslint,
68
+ etc. Our policy is to wait until these projects fully support
69
+ the new version of TypeScript, and/or without emitting warnings during these tests, before publishing.
68
70
 
69
71
  ### A note about versioning
70
72
 
71
- Strict semver is a little complicated, as Typescript itself does not adhere to semver. So our "best effort" policy is:
73
+ Strict semver is a little complicated, as TypeScript itself does not adhere to semver. So our "best effort" policy is:
72
74
 
73
75
  - Each update to the minimum Node target (e.g., Node 18 to Node 20), or a change to a major compiler output option
74
76
  (e.g. `module`, `target` or `moduleResolution`) will result in a new major version of this module.
75
77
  We coordinate this with whatever the latest LTS version of Node is currently supported by Amazon Lambda,
76
78
  Google Cloud Functions, and Azure Functions.
77
- - Each new "major" version of Typescript (e.g. `4.2.x` to `4.3.x`) will result in a new minor version of this module.
78
- - A new minor update of Typescript (e.g. `4.3.1` to `4.3.2`) _may_ result in a patch, in
79
- a situation where a specific need or issue requires setting a new minimum version of Typescript.
79
+ - Each new "major" version of TypeScript (e.g. `5.7.x` to `5.8.x`) will result in a new minor version of this module.
80
+ - A new minor update of TypeScript (e.g. `5.7.2` to `5.7.3`) _may_ result in a patch, in
81
+ a situation where a specific need or issue requires setting a new minimum version of TypeScript.
80
82
 
81
- Bear in mind, any update of Typescript can potentially break your build. But hopefully in a way that's useful.
83
+ Bear in mind, any update of TypeScript can potentially break your build. But hopefully in a way that's useful.
82
84
 
83
85
  ### Installation
84
86
 
@@ -86,7 +88,7 @@ Bear in mind, any update of Typescript can potentially break your build. But hop
86
88
  npm add -D @checkdigit/typescript-config
87
89
  ```
88
90
 
89
- Note: you do not need to explicitly install Typescript itself, as the most recent supported version comes in as a
91
+ Note: you do not need to explicitly install TypeScript itself, as the most recent supported version comes in as a
90
92
  peer dependency of `@checkdigit/typescript-config`.
91
93
 
92
94
  Make sure your project's `tsconfig.json` extends `@checkdigit/typescript-config`.
@@ -99,9 +101,9 @@ Make sure your project's `tsconfig.json` extends `@checkdigit/typescript-config`
99
101
  }
100
102
  ```
101
103
 
102
- Note this configuration has `moduleResolution` set to `bundler`. This requires that you use the `builder` command
103
- to produce working code for deployment. However, for simply running Jest tests, this is not necessary if
104
- used in conjunction with [`@checkdigit/jest-config`](https://github.com/checkdigit/jest-config).
104
+ Note this configuration has `moduleResolution` set to `bundler`.
105
+ This requires the use of the `builder` command
106
+ to produce working code for deployment.
105
107
 
106
108
  ## License
107
109
 
package/package.json CHANGED
@@ -1 +1 @@
1
- {"name":"@checkdigit/typescript-config","version":"9.1.0-PR.71-3ed3","description":"Check Digit standard Typescript configuration","homepage":"https://github.com/checkdigit/typescript-config#readme","bugs":{"url":"https://github.com/checkdigit/typescript-config/issues"},"repository":{"type":"git","url":"git+https://github.com/checkdigit/typescript-config.git"},"license":"MIT","author":"Check Digit, LLC","type":"module","exports":{".":{"types":"./dist-types/index.d.ts","import":"./dist-mjs/index.mjs","default":"./tsconfig.json"}},"bin":{"builder":"./bin/builder.mjs"},"files":["bin","tsconfig.json","src","dist-types","dist-mjs","!src/**/test/**","!src/**/*.test.ts","!src/**/*.spec.ts","!dist-types/**/test/**","!dist-types/**/*.test.d.ts","!dist-types/**/*.spec.d.ts","!dist-mjs/**/test/**","!dist-mjs/**/*.test.mjs","!dist-mjs/**/*.spec.mjs","SECURITY.md"],"scripts":{"build":"npm run build:builder && npm run build:types && npm run build:mjs && npm run build:mjs-bundle && npm run build:mjs-bundle-minify && npm run build:mjs-bundle-no-external","build:builder":"esbuild src/builder.ts --bundle --platform=node --format=esm --external:typescript --external:esbuild --outfile=build-builder/builder.mjs && mkdir -p bin && { echo '#!/usr/bin/env node'; cat build-builder/builder.mjs; } > bin/builder.mjs && chmod +x bin/builder.mjs","build:dist-mjs":"rimraf dist-mjs && npx builder --type=module --sourceMap --outDir=dist-mjs && node dist-mjs/index.mjs","build:dist-types":"rimraf dist-types && npx builder --type=types --outDir=dist-types","build:mjs":"rimraf build-mjs && bin/builder.mjs --type=module --outDir=build-mjs","build:mjs-bundle":"rimraf build-mjs-bundle && bin/builder.mjs --type=module --outDir=build-mjs-bundle --entryPoint=test/index.ts --outFile=test/index.mjs","build:mjs-bundle-minify":"rimraf build-mjs-bundle-minify && bin/builder.mjs --type=module --minify --outDir=build-mjs-bundle-minify --entryPoint=test/index.ts --outFile=test/index.mjs","build:mjs-bundle-no-external":"rimraf build-mjs-bundle-no-external && bin/builder.mjs --type=module --external=./node_modules/* --outDir=build-mjs-bundle-no-external --entryPoint=test/index.ts --outFile=test/index.mjs --minify","build:types":"rimraf build-types && bin/builder.mjs --type=types --outDir=build-types","ci:compile":"tsc --noEmit --rootDir src","ci:lint":"npm run lint","ci:style":"npm run prettier","ci:test":"npm run build && npm run test:node-mjs && npm run test:mjs && npm run test:mjs-bundle && npm run test:mjs-bundle-no-external","lint":"eslint --max-warnings 0 .","lint:fix":"eslint . --fix","prepare":"","prepublishOnly":"npm run build:builder && npm run build:dist-types && npm run build:dist-mjs","prettier":"prettier --ignore-path .gitignore --list-different .","prettier:fix":"prettier --ignore-path .gitignore --write .","test":"npm run ci:compile && npm run ci:test && npm run ci:lint && npm run ci:style","test:mjs":"node --test build-mjs/test/index.mjs","test:mjs-bundle":"node --test build-mjs-bundle/test/index.mjs","test:mjs-bundle-minify":"node --test build-mjs-bundle-minify/test/index.mjs","test:mjs-bundle-no-external":"node --test build-mjs-bundle-no-external/test/index.mjs","test:node-mjs":"node --disable-warning ExperimentalWarning --experimental-strip-types --test-timeout 600000 --test \"src/**/*.spec.ts\""},"prettier":"@checkdigit/prettier-config","devDependencies":{"@checkdigit/prettier-config":"^6.2.0","@eslint/js":"^9.21.0","@eslint/json":"^0.10.0","@eslint/markdown":"^6.2.2","@types/uuid":"^10.0.0","@typescript-eslint/parser":"^8.25.0","eslint":"^9.21.0","eslint-config-prettier":"^10.0.2","eslint-plugin-jest":"^28.11.0","eslint-plugin-yml":"^1.17.0","rimraf":"^6.0.1","typescript-eslint":"^8.25.0"},"peerDependencies":{"@swc-node/register":"1.10.9","@types/node":">=22","esbuild":"0.25.0","typescript":"5.8.1-rc"},"engines":{"node":">=22.11"},"overrides":{"typescript":"5.8.1-rc"}}
1
+ {"name":"@checkdigit/typescript-config","version":"9.1.0-PR.71-fee0","description":"Check Digit standard Typescript configuration","homepage":"https://github.com/checkdigit/typescript-config#readme","bugs":{"url":"https://github.com/checkdigit/typescript-config/issues"},"repository":{"type":"git","url":"git+https://github.com/checkdigit/typescript-config.git"},"license":"MIT","author":"Check Digit, LLC","type":"module","exports":{".":{"types":"./dist-types/index.d.ts","import":"./dist-mjs/index.mjs","default":"./tsconfig.json"}},"bin":{"builder":"./bin/builder.mjs"},"files":["bin","tsconfig.json","src","dist-types","dist-mjs","!src/**/test/**","!src/**/*.test.ts","!src/**/*.spec.ts","!dist-types/**/test/**","!dist-types/**/*.test.d.ts","!dist-types/**/*.spec.d.ts","!dist-mjs/**/test/**","!dist-mjs/**/*.test.mjs","!dist-mjs/**/*.spec.mjs","SECURITY.md"],"scripts":{"build":"npm run build:builder && npm run build:types && npm run build:mjs && npm run build:mjs-bundle && npm run build:mjs-bundle-minify && npm run build:mjs-bundle-no-external","build:builder":"esbuild src/builder.ts --bundle --platform=node --format=esm --external:typescript --external:esbuild --outfile=build-builder/builder.mjs && mkdir -p bin && { echo '#!/usr/bin/env node'; cat build-builder/builder.mjs; } > bin/builder.mjs && chmod +x bin/builder.mjs","build:dist-mjs":"rimraf dist-mjs && npx builder --type=module --sourceMap --outDir=dist-mjs && node dist-mjs/index.mjs","build:dist-types":"rimraf dist-types && npx builder --type=types --outDir=dist-types","build:mjs":"rimraf build-mjs && bin/builder.mjs --type=module --outDir=build-mjs","build:mjs-bundle":"rimraf build-mjs-bundle && bin/builder.mjs --type=module --outDir=build-mjs-bundle --entryPoint=test/index.ts --outFile=test/index.mjs","build:mjs-bundle-minify":"rimraf build-mjs-bundle-minify && bin/builder.mjs --type=module --minify --outDir=build-mjs-bundle-minify --entryPoint=test/index.ts --outFile=test/index.mjs","build:mjs-bundle-no-external":"rimraf build-mjs-bundle-no-external && bin/builder.mjs --type=module --external=./node_modules/* --outDir=build-mjs-bundle-no-external --entryPoint=test/index.ts --outFile=test/index.mjs --minify","build:types":"rimraf build-types && bin/builder.mjs --type=types --outDir=build-types","ci:compile":"tsc --noEmit --rootDir src","ci:lint":"npm run lint","ci:style":"npm run prettier","ci:test":"npm run build && npm run test:node-mjs && npm run test:mjs && npm run test:mjs-bundle && npm run test:mjs-bundle-no-external","lint":"eslint --max-warnings 0 .","lint:fix":"eslint . --fix","prepare":"","prepublishOnly":"npm run build:builder && npm run build:dist-types && npm run build:dist-mjs","prettier":"prettier --ignore-path .gitignore --list-different .","prettier:fix":"prettier --ignore-path .gitignore --write .","test":"npm run ci:compile && npm run ci:test && npm run ci:lint && npm run ci:style","test:mjs":"node --test build-mjs/test/index.mjs","test:mjs-bundle":"node --test build-mjs-bundle/test/index.mjs","test:mjs-bundle-minify":"node --test build-mjs-bundle-minify/test/index.mjs","test:mjs-bundle-no-external":"node --test build-mjs-bundle-no-external/test/index.mjs","test:node-mjs":"node --disable-warning ExperimentalWarning --experimental-strip-types --test-timeout 600000 --test \"src/**/*.spec.ts\""},"prettier":"@checkdigit/prettier-config","devDependencies":{"@checkdigit/prettier-config":"^6.2.0","@eslint/js":"^9.21.0","@eslint/json":"^0.10.0","@eslint/markdown":"^6.2.2","@types/uuid":"^10.0.0","@typescript-eslint/parser":"^8.25.0","eslint":"^9.21.0","eslint-config-prettier":"^10.0.2","eslint-plugin-jest":"^28.11.0","eslint-plugin-yml":"^1.17.0","rimraf":"^6.0.1","typescript-eslint":"^8.25.0"},"peerDependencies":{"@swc-node/register":"1.10.9","@types/node":">=22.11","esbuild":"0.25.0","typescript":">=5.8.2 <5.9.0"},"engines":{"node":">=22.11"},"overrides":{"typescript":">=5.8.2 <5.9.0"}}