@web-ts-toolkit/express-runtime 0.7.0 → 0.8.0

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 (3) hide show
  1. package/README.md +7 -7
  2. package/cli.js +9 -9
  3. package/package.json +2 -2
package/README.md CHANGED
@@ -80,12 +80,12 @@ startLocalServer(app, {
80
80
 
81
81
  ### CLI — dev (local server)
82
82
 
83
- The `web-ts-toolkit-express-runtime dev` command runs any module that
83
+ The `wtt-express-runtime dev` command runs any module that
84
84
  default-exports an Express app (or an async function returning one) as a local
85
85
  dev server:
86
86
 
87
87
  ```sh
88
- npx web-ts-toolkit-express-runtime dev ./dist/app.js --port 3000 --host localhost
88
+ npx wtt-express-runtime dev ./dist/app.js --port 3000 --host localhost
89
89
  ```
90
90
 
91
91
  ```ts
@@ -115,13 +115,13 @@ with `createServerlessHandler`, then bundles it with `tsup` into a
115
115
  deployment-ready file:
116
116
 
117
117
  ```sh
118
- npx web-ts-toolkit-express-runtime build ./src/app.ts --out-dir netlify/functions
118
+ npx wtt-express-runtime build ./src/app.ts --out-dir netlify/functions
119
119
  ```
120
120
 
121
121
  With an optional init hook (DB connections, cache warmup, etc.):
122
122
 
123
123
  ```sh
124
- npx web-ts-toolkit-express-runtime build ./src/app.ts --init ./src/init.ts --out-dir netlify/functions
124
+ npx wtt-express-runtime build ./src/app.ts --init ./src/init.ts --out-dir netlify/functions
125
125
  ```
126
126
 
127
127
  ```ts
@@ -146,8 +146,8 @@ responses — letting you smoke-test the exact `build` output without a
146
146
  serverless platform:
147
147
 
148
148
  ```sh
149
- npx web-ts-toolkit-express-runtime build ./src/app.ts --out-dir dist
150
- npx web-ts-toolkit-express-runtime start ./dist/handler.js --port 9000
149
+ npx wtt-express-runtime build ./src/app.ts --out-dir dist
150
+ npx wtt-express-runtime start ./dist/handler.js --port 9000
151
151
  ```
152
152
 
153
153
  The handler module must export a `handler` function (named or default) that
@@ -272,7 +272,7 @@ interface Logger {
272
272
 
273
273
  ## CLI
274
274
 
275
- ### `web-ts-toolkit-express-runtime <command> <app-module> [options]`
275
+ ### `wtt-express-runtime <command> <app-module> [options]`
276
276
 
277
277
  Omitting `<command>` defaults to `dev` for backward compatibility.
278
278
 
package/cli.js CHANGED
@@ -203,13 +203,13 @@ function readValue(argv, index, name) {
203
203
  return value;
204
204
  }
205
205
  function printHelp() {
206
- console.log(`web-ts-toolkit-express-runtime
206
+ console.log(`wtt-express-runtime
207
207
 
208
208
  Run an Express app locally, bundle it as a serverless handler, or run the bundle.
209
209
 
210
210
  Usage:
211
- web-ts-toolkit-express-runtime <command> <app-module> [options]
212
- web-ts-toolkit-express-runtime <app-module> [options] (alias for dev)
211
+ wtt-express-runtime <command> <app-module> [options]
212
+ wtt-express-runtime <app-module> [options] (alias for dev)
213
213
 
214
214
  Commands:
215
215
  dev Run the Express app as a local dev server
@@ -242,12 +242,12 @@ Global options:
242
242
  -h, --help Show this help message
243
243
 
244
244
  Examples:
245
- web-ts-toolkit-express-runtime dev ./dist/app.js
246
- web-ts-toolkit-express-runtime dev ./dist/app.js --port 3000 --host localhost
247
- web-ts-toolkit-express-runtime build ./src/app.ts --out-dir netlify/functions
248
- web-ts-toolkit-express-runtime build ./src/app.ts --init ./src/init.ts --format esm
249
- web-ts-toolkit-express-runtime start ./netlify/functions/handler.js --port 9000
250
- web-ts-toolkit-express-runtime build ./src/app.ts && web-ts-toolkit-express-runtime start ./dist/handler.js
245
+ wtt-express-runtime dev ./dist/app.js
246
+ wtt-express-runtime dev ./dist/app.js --port 3000 --host localhost
247
+ wtt-express-runtime build ./src/app.ts --out-dir netlify/functions
248
+ wtt-express-runtime build ./src/app.ts --init ./src/init.ts --format esm
249
+ wtt-express-runtime start ./netlify/functions/handler.js --port 9000
250
+ wtt-express-runtime build ./src/app.ts && wtt-express-runtime start ./dist/handler.js
251
251
 
252
252
  Notes:
253
253
  - In dev mode, the CLI evaluates arbitrary code from <app-module> in the current process.
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@web-ts-toolkit/express-runtime",
3
3
  "description": "Express app factory plus serverless handler and local dev server helpers",
4
4
  "homepage": "https://web-ts-toolkit.pages.dev/docs/packages/express-runtime",
5
- "version": "0.7.0",
5
+ "version": "0.8.0",
6
6
  "sideEffects": false,
7
7
  "keywords": [
8
8
  "express",
@@ -16,7 +16,7 @@
16
16
  "module": "./index.mjs",
17
17
  "types": "./index.d.ts",
18
18
  "bin": {
19
- "web-ts-toolkit-express-runtime": "./cli.js"
19
+ "wtt-express-runtime": "./cli.js"
20
20
  },
21
21
  "exports": {
22
22
  ".": {