@chidchanun/bcp 0.1.28 → 0.1.29
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.
- package/README.md +119 -13
- package/docs/README.md +164 -81
- package/docs/developer-tools.md +175 -78
- package/docs/docs-web-manifest.json +88 -0
- package/docs/generators.md +149 -0
- package/docs/project-metadata.md +112 -0
- package/docs/releases/0.1.29.md +170 -0
- package/package.json +1 -1
- package/packages/cli/src/args.ts +96 -0
- package/packages/cli/src/developer-tools-v2.ts +629 -0
- package/packages/cli/src/developer-tools.ts +115 -0
- package/packages/cli/src/generate.ts +475 -0
- package/packages/cli/src/index.ts +69 -0
package/README.md
CHANGED
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
BCP Framework is a React full-stack framework focused on file-based routing, SSR, server data loading, guarded application flows, API routes, authentication, database access, validation, logging, uploads, storage and standalone production deployment.
|
|
4
4
|
|
|
5
|
-
> **Development target:** `0.1.
|
|
5
|
+
> **Development target:** `0.1.29`
|
|
6
6
|
>
|
|
7
|
-
> BCP is pre-1.0. The `0.1.
|
|
7
|
+
> BCP is pre-1.0. The `0.1.29` source adds the Developer Experience milestone and remains an unreleased development target until local validation, RC checks, tagging and npm publication complete.
|
|
8
8
|
|
|
9
9
|
## Current capabilities
|
|
10
10
|
|
|
@@ -24,8 +24,9 @@ BCP Framework is a React full-stack framework focused on file-based routing, SSR
|
|
|
24
24
|
| Uploads | Buffered multipart helpers and production multipart streaming |
|
|
25
25
|
| Storage | Local + S3-compatible adapters, streaming, listing, copy/move, metadata, bulk delete and signed S3 URLs |
|
|
26
26
|
| Caching | Response cache and revalidation primitives |
|
|
27
|
-
| Developer tools | `doctor
|
|
27
|
+
| Developer tools | Project generators, `doctor` / `inspect` v2, updater, route inspection and project metadata |
|
|
28
28
|
| Production | Standalone build, hardening gateway, graceful shutdown, trusted-proxy controls and HTTP timeouts |
|
|
29
|
+
| Documentation | Markdown source map plus `docs/docs-web-manifest.json` for `bcp-docs-web` |
|
|
29
30
|
|
|
30
31
|
## Requirements
|
|
31
32
|
|
|
@@ -115,6 +116,37 @@ app/api/users/[id]/route.ts /api/users/:id
|
|
|
115
116
|
|
|
116
117
|
Read more: [Routing](docs/routing.md)
|
|
117
118
|
|
|
119
|
+
## Project generators — 0.1.29
|
|
120
|
+
|
|
121
|
+
BCP `0.1.29` adds generators for common framework files:
|
|
122
|
+
|
|
123
|
+
```bash
|
|
124
|
+
bcp generate page dashboard/users
|
|
125
|
+
bcp generate page users/[id]
|
|
126
|
+
bcp generate api users
|
|
127
|
+
bcp generate middleware
|
|
128
|
+
bcp generate migration create_users
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
Generated targets:
|
|
132
|
+
|
|
133
|
+
```text
|
|
134
|
+
page -> app/<route>/page.tsx
|
|
135
|
+
api -> app/api/<route>/route.ts
|
|
136
|
+
middleware -> middleware.ts
|
|
137
|
+
migration -> migrations/<timestamp>_<name>.ts
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
Page/API/middleware generators do not overwrite existing files unless `--force` is explicitly supplied:
|
|
141
|
+
|
|
142
|
+
```bash
|
|
143
|
+
bcp generate page dashboard/users --force
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
Migration generation reuses the existing database migration implementation so migration naming and format remain centralized.
|
|
147
|
+
|
|
148
|
+
Read more: [Project Generators](docs/generators.md)
|
|
149
|
+
|
|
118
150
|
## Server data, guards and actions
|
|
119
151
|
|
|
120
152
|
Server loaders live next to their route in `loader.ts`. Route authorization can be defined in `guard.ts`, while route-owned mutations live in `actions.ts`.
|
|
@@ -270,7 +302,7 @@ Read more: [Storage and File Delivery](docs/storage.md)
|
|
|
270
302
|
|
|
271
303
|
### Storage Ecosystem — 0.1.27
|
|
272
304
|
|
|
273
|
-
BCP `0.1.27`
|
|
305
|
+
BCP `0.1.27` added a richer, additive object-storage API without invalidating older `StorageAdapter` implementations:
|
|
274
306
|
|
|
275
307
|
```ts
|
|
276
308
|
import {
|
|
@@ -373,6 +405,53 @@ Trusted proxy mode is disabled by default. Enable `BCP_TRUST_PROXY=true` only wh
|
|
|
373
405
|
|
|
374
406
|
Read more: [Production Hardening](docs/production-hardening.md)
|
|
375
407
|
|
|
408
|
+
## Doctor and Inspect v2 — 0.1.29
|
|
409
|
+
|
|
410
|
+
`bcp doctor` now includes additional project/runtime diagnostics for:
|
|
411
|
+
|
|
412
|
+
```text
|
|
413
|
+
lockfile / package manager
|
|
414
|
+
multiple framework dependency declarations
|
|
415
|
+
standalone production artifact
|
|
416
|
+
Docker + reproducible install guidance
|
|
417
|
+
storage provider
|
|
418
|
+
production-hardening environment validity
|
|
419
|
+
```
|
|
420
|
+
|
|
421
|
+
`bcp inspect` keeps its existing fields and adds a machine-readable `project` object with project metadata, selected presets and runtime/deployment information.
|
|
422
|
+
|
|
423
|
+
```powershell
|
|
424
|
+
npm exec -- bcp-framework doctor --json
|
|
425
|
+
npm exec -- bcp-framework inspect --json
|
|
426
|
+
```
|
|
427
|
+
|
|
428
|
+
Read more: [Developer Tools](docs/developer-tools.md)
|
|
429
|
+
|
|
430
|
+
## Project metadata — 0.1.29
|
|
431
|
+
|
|
432
|
+
New `create-bcp-app` projects include `bcp.project.json`:
|
|
433
|
+
|
|
434
|
+
```json
|
|
435
|
+
{
|
|
436
|
+
"schemaVersion": 1,
|
|
437
|
+
"framework": "bcp",
|
|
438
|
+
"projectName": "my-app",
|
|
439
|
+
"packageManager": "npm",
|
|
440
|
+
"presets": {
|
|
441
|
+
"tailwind": true,
|
|
442
|
+
"database": "mysql",
|
|
443
|
+
"auth": "jwt-cookie",
|
|
444
|
+
"storage": "local"
|
|
445
|
+
}
|
|
446
|
+
}
|
|
447
|
+
```
|
|
448
|
+
|
|
449
|
+
This file stores only non-secret scaffold metadata. Credentials, database passwords, access keys, JWT/session secrets and tokens stay in environment/server-only configuration.
|
|
450
|
+
|
|
451
|
+
Existing projects without the file continue to work; diagnostic tooling falls back to project files where practical.
|
|
452
|
+
|
|
453
|
+
Read more: [Project Metadata](docs/project-metadata.md)
|
|
454
|
+
|
|
376
455
|
## Windows CLI
|
|
377
456
|
|
|
378
457
|
Microsoft SQL Server can install another executable named `bcp.exe`. BCP publishes the collision-free alias `bcp-framework`.
|
|
@@ -386,6 +465,7 @@ npm exec -- bcp-framework --version
|
|
|
386
465
|
npm exec -- bcp-framework doctor
|
|
387
466
|
npm exec -- bcp-framework inspect
|
|
388
467
|
npm exec -- bcp-framework routes
|
|
468
|
+
npm exec -- bcp-framework generate page dashboard/users
|
|
389
469
|
npm exec -- bcp-framework dev
|
|
390
470
|
npm exec -- bcp-framework build
|
|
391
471
|
```
|
|
@@ -398,7 +478,7 @@ Read more: [Developer Tools](docs/developer-tools.md)
|
|
|
398
478
|
bcp update
|
|
399
479
|
bcp update --check
|
|
400
480
|
bcp update --dry-run
|
|
401
|
-
bcp update 0.1.
|
|
481
|
+
bcp update 0.1.29
|
|
402
482
|
bcp update next
|
|
403
483
|
```
|
|
404
484
|
|
|
@@ -420,16 +500,39 @@ A version must not be tagged or published until its RC and packed-package verifi
|
|
|
420
500
|
|
|
421
501
|
Read more: [Releasing](docs/releasing.md)
|
|
422
502
|
|
|
423
|
-
## Documentation source
|
|
503
|
+
## Documentation source and `bcp-docs-web`
|
|
424
504
|
|
|
425
505
|
The `docs/` directory is the authored source for **`bcp-docs-web`**.
|
|
426
506
|
|
|
507
|
+
Starting with `0.1.29`, docs-web should consume:
|
|
508
|
+
|
|
509
|
+
```text
|
|
510
|
+
docs/docs-web-manifest.json
|
|
511
|
+
```
|
|
512
|
+
|
|
513
|
+
for sidebar/navigation and route mapping. Markdown files remain the documentation content source of truth.
|
|
514
|
+
|
|
515
|
+
The manifest contains:
|
|
516
|
+
|
|
517
|
+
```text
|
|
518
|
+
section id/title
|
|
519
|
+
website route
|
|
520
|
+
Markdown source file
|
|
521
|
+
page title
|
|
522
|
+
version target
|
|
523
|
+
release state
|
|
524
|
+
release routes
|
|
525
|
+
```
|
|
526
|
+
|
|
427
527
|
Recommended starting points:
|
|
428
528
|
|
|
529
|
+
- [Docs-Web Manifest](docs/docs-web-manifest.json)
|
|
429
530
|
- [Documentation Source Map](docs/README.md)
|
|
430
531
|
- [Getting Started](docs/getting-started.md)
|
|
431
532
|
- [Configuration](docs/configuration.md)
|
|
533
|
+
- [Project Metadata](docs/project-metadata.md)
|
|
432
534
|
- [Routing](docs/routing.md)
|
|
535
|
+
- [Project Generators](docs/generators.md)
|
|
433
536
|
- [Server Data Loaders](docs/server-data-loaders.md)
|
|
434
537
|
- [Route Guards](docs/route-guards.md)
|
|
435
538
|
- [Form Actions](docs/form-actions.md)
|
|
@@ -459,18 +562,21 @@ Recommended starting points:
|
|
|
459
562
|
| `0.1.26` | S3-Compatible Storage and Production Streaming |
|
|
460
563
|
| `0.1.27` | Storage Ecosystem |
|
|
461
564
|
| `0.1.28` | Production Hardening |
|
|
565
|
+
| `0.1.29` | Developer Experience |
|
|
462
566
|
|
|
463
567
|
## Next direction
|
|
464
568
|
|
|
465
|
-
After `0.1.
|
|
569
|
+
After `0.1.29`, the planned major milestone is **`0.2.0 — Framework Platform`**.
|
|
570
|
+
|
|
571
|
+
The focus should be consolidation rather than unrelated feature growth:
|
|
466
572
|
|
|
467
|
-
1.
|
|
468
|
-
2.
|
|
469
|
-
3.
|
|
470
|
-
4.
|
|
471
|
-
5.
|
|
573
|
+
1. public API consistency and compatibility expectations,
|
|
574
|
+
2. production-runtime stabilization across supported deployment paths,
|
|
575
|
+
3. documentation completeness and docs-web integration,
|
|
576
|
+
4. migration guidance for pre-`0.2.0` applications,
|
|
577
|
+
5. a documented platform baseline for routing, data, auth, database, storage and runtime APIs.
|
|
472
578
|
|
|
473
|
-
These are roadmap
|
|
579
|
+
These are roadmap goals, not `0.1.29` guarantees.
|
|
474
580
|
|
|
475
581
|
## License
|
|
476
582
|
|
package/docs/README.md
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
# BCP Framework Documentation Source
|
|
2
2
|
|
|
3
|
-
The `docs/` directory is the documentation source of truth for BCP Framework and is intentionally organized for
|
|
3
|
+
The `docs/` directory is the documentation source of truth for BCP Framework and is intentionally organized for **`bcp-docs-web`**.
|
|
4
4
|
|
|
5
|
-
> **Documentation target:** BCP Framework `0.1.
|
|
5
|
+
> **Documentation target:** BCP Framework `0.1.29`
|
|
6
6
|
>
|
|
7
|
-
> **Release state:** unreleased development target. Do not label `0.1.
|
|
7
|
+
> **Release state:** unreleased development target. Do not label `0.1.29` as published until RC validation, tagging and npm publication complete.
|
|
8
8
|
|
|
9
9
|
## Documentation flow
|
|
10
10
|
|
|
@@ -13,10 +13,45 @@ BCP Framework source/tests
|
|
|
13
13
|
↓
|
|
14
14
|
docs/
|
|
15
15
|
↓
|
|
16
|
+
Markdown content + docs-web manifest
|
|
17
|
+
↓
|
|
16
18
|
bcp-docs-web
|
|
17
19
|
```
|
|
18
20
|
|
|
19
|
-
Framework source and tests are authoritative for behavior. Markdown under `docs/` is the authored documentation layer. `bcp-docs-web` should render, organize and search these sources
|
|
21
|
+
Framework source and tests are authoritative for behavior. Markdown under `docs/` is the authored documentation layer. `bcp-docs-web` should render, organize and search these sources rather than becoming a competing source of truth.
|
|
22
|
+
|
|
23
|
+
## Docs-web navigation contract — 0.1.29
|
|
24
|
+
|
|
25
|
+
`docs/docs-web-manifest.json` is the explicit navigation and route contract for the docs website.
|
|
26
|
+
|
|
27
|
+
It defines:
|
|
28
|
+
|
|
29
|
+
```text
|
|
30
|
+
schema version
|
|
31
|
+
framework/version target
|
|
32
|
+
release state
|
|
33
|
+
section IDs/titles
|
|
34
|
+
website routes
|
|
35
|
+
Markdown source files
|
|
36
|
+
page titles
|
|
37
|
+
release routes
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
Recommended docs-web workflow:
|
|
41
|
+
|
|
42
|
+
```text
|
|
43
|
+
read docs/docs-web-manifest.json
|
|
44
|
+
↓
|
|
45
|
+
generate sidebar + route map
|
|
46
|
+
↓
|
|
47
|
+
load referenced Markdown file
|
|
48
|
+
↓
|
|
49
|
+
render content/search/prev-next
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
Do not duplicate this mapping in a second hard-coded sidebar unless the website needs a temporary bootstrap fallback.
|
|
53
|
+
|
|
54
|
+
Markdown remains the content source; the manifest contains navigation metadata only.
|
|
20
55
|
|
|
21
56
|
## Update rule
|
|
22
57
|
|
|
@@ -24,12 +59,15 @@ When framework behavior changes:
|
|
|
24
59
|
|
|
25
60
|
1. Update framework source.
|
|
26
61
|
2. Add/update regression tests.
|
|
27
|
-
3. Update the matching file under `docs/`.
|
|
28
|
-
4. Update `docs/
|
|
29
|
-
5.
|
|
62
|
+
3. Update the matching Markdown file under `docs/`.
|
|
63
|
+
4. Update `docs/docs-web-manifest.json` when routes/navigation change.
|
|
64
|
+
5. Update `docs/releases/<version>.md`.
|
|
65
|
+
6. Change release state to published only after npm publication succeeds.
|
|
30
66
|
|
|
31
67
|
## Recommended `bcp-docs-web` navigation
|
|
32
68
|
|
|
69
|
+
The current manifest groups documentation into:
|
|
70
|
+
|
|
33
71
|
```text
|
|
34
72
|
Getting Started
|
|
35
73
|
Routing & Data
|
|
@@ -37,7 +75,7 @@ Authentication
|
|
|
37
75
|
Database
|
|
38
76
|
Runtime & Infrastructure
|
|
39
77
|
Storage & Uploads
|
|
40
|
-
|
|
78
|
+
Developer Experience
|
|
41
79
|
Releases
|
|
42
80
|
```
|
|
43
81
|
|
|
@@ -48,6 +86,7 @@ Releases
|
|
|
48
86
|
| `/docs/getting-started` | `getting-started.md` | Create and run a BCP application |
|
|
49
87
|
| `/docs/configuration` | `configuration.md` | Framework configuration/environment |
|
|
50
88
|
| `/docs/application-modules` | `application-modules.md` | Client/server boundaries |
|
|
89
|
+
| `/docs/project-metadata` | `project-metadata.md` | `bcp.project.json` schema and security boundary |
|
|
51
90
|
| `/docs/deployment` | `deployment.md` | Standalone production deployment |
|
|
52
91
|
| `/docs/updating` | `updating.md` | Framework upgrades |
|
|
53
92
|
|
|
@@ -84,11 +123,10 @@ Releases
|
|
|
84
123
|
| --- | --- | --- |
|
|
85
124
|
| `/docs/middleware` | `middleware.md` | Middleware System v2 |
|
|
86
125
|
| `/docs/hydration` | `hydration.md` | SSR/client hydration parity |
|
|
87
|
-
| `/docs/developer-tools` | `developer-tools.md` | `doctor` / `inspect` |
|
|
88
126
|
| `/docs/development-logging` | `development-logging.md` | Logging/observability |
|
|
89
127
|
| `/docs/caching` | `caching.md` | Cache/revalidation |
|
|
90
128
|
| `/docs/security` | `security.md` | Security/body limits |
|
|
91
|
-
| `/docs/production-hardening` | `production-hardening.md` | Graceful shutdown, trusted proxy and
|
|
129
|
+
| `/docs/production-hardening` | `production-hardening.md` | Graceful shutdown, trusted proxy and timeouts |
|
|
92
130
|
|
|
93
131
|
### Storage & Uploads
|
|
94
132
|
|
|
@@ -99,6 +137,13 @@ Releases
|
|
|
99
137
|
| `/docs/storage-ecosystem` | `storage-ecosystem.md` | Listing, copy/move, metadata, bulk delete, signed URLs |
|
|
100
138
|
| `/docs/s3-storage` | `s3-storage.md` | S3/R2/MinIO adapter and direct object access |
|
|
101
139
|
|
|
140
|
+
### Developer Experience
|
|
141
|
+
|
|
142
|
+
| Website route | Markdown source | Purpose |
|
|
143
|
+
| --- | --- | --- |
|
|
144
|
+
| `/docs/generators` | `generators.md` | Page/API/middleware/migration generators |
|
|
145
|
+
| `/docs/developer-tools` | `developer-tools.md` | Doctor/Inspect v2 and diagnostics |
|
|
146
|
+
|
|
102
147
|
## API Reference ownership
|
|
103
148
|
|
|
104
149
|
Recommended entrypoint groups:
|
|
@@ -156,16 +201,16 @@ bcp/middleware
|
|
|
156
201
|
|
|
157
202
|
### Storage & Uploads
|
|
158
203
|
|
|
159
|
-
- buffered multipart
|
|
204
|
+
- buffered multipart upload APIs
|
|
160
205
|
- production streaming multipart upload (`storeMultipartFile()`)
|
|
161
206
|
- backward-compatible `StorageAdapter` contract
|
|
162
207
|
- local filesystem storage
|
|
163
|
-
- S3/R2/MinIO-compatible storage
|
|
208
|
+
- Amazon S3 / Cloudflare R2 / MinIO-compatible storage
|
|
164
209
|
- streaming reads/writes and byte ranges
|
|
165
210
|
- ETag/Last-Modified file delivery
|
|
166
211
|
- upload/storage limits and abort cleanup
|
|
167
212
|
- object listing with cursors
|
|
168
|
-
-
|
|
213
|
+
- copy and move
|
|
169
214
|
- portable user metadata
|
|
170
215
|
- bulk deletion
|
|
171
216
|
- S3 presigned read/write URLs
|
|
@@ -179,66 +224,61 @@ bcp/middleware
|
|
|
179
224
|
- transactions
|
|
180
225
|
- migrations/status/rollback
|
|
181
226
|
|
|
182
|
-
### Developer Experience
|
|
227
|
+
### Developer Experience — 0.1.29
|
|
183
228
|
|
|
184
229
|
- `create-bcp-app`
|
|
230
|
+
- non-secret `bcp.project.json`
|
|
231
|
+
- `bcp generate page`
|
|
232
|
+
- `bcp generate api`
|
|
233
|
+
- `bcp generate middleware`
|
|
234
|
+
- `bcp generate migration`
|
|
185
235
|
- `bcp update`
|
|
186
|
-
-
|
|
187
|
-
-
|
|
236
|
+
- Doctor/Inspect v2
|
|
237
|
+
- lockfile/package-manager diagnostics
|
|
238
|
+
- duplicate framework declaration checks
|
|
239
|
+
- storage/provider diagnostics
|
|
240
|
+
- production-build/Docker/hardening diagnostics
|
|
188
241
|
- Windows-safe `bcp-framework` alias
|
|
189
|
-
-
|
|
190
|
-
- unit/integration/E2E/package/RC checks
|
|
242
|
+
- `docs/docs-web-manifest.json`
|
|
191
243
|
|
|
192
|
-
## BCP 0.1.
|
|
244
|
+
## BCP 0.1.29 documentation focus
|
|
193
245
|
|
|
194
|
-
###
|
|
246
|
+
### Project generators
|
|
195
247
|
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
registerShutdownHook,
|
|
202
|
-
} from "bcp/server";
|
|
248
|
+
```bash
|
|
249
|
+
bcp generate page dashboard/users
|
|
250
|
+
bcp generate api users
|
|
251
|
+
bcp generate middleware
|
|
252
|
+
bcp generate migration create_users
|
|
203
253
|
```
|
|
204
254
|
|
|
205
|
-
|
|
255
|
+
Page/API/middleware generation requires `--force` before replacing existing target files.
|
|
206
256
|
|
|
207
|
-
|
|
208
|
-
BCP_REQUEST_TIMEOUT_MS=120000
|
|
209
|
-
BCP_HEADERS_TIMEOUT_MS=66000
|
|
210
|
-
BCP_KEEP_ALIVE_TIMEOUT_MS=65000
|
|
211
|
-
BCP_SHUTDOWN_TIMEOUT_MS=10000
|
|
212
|
-
BCP_TRUST_PROXY=false
|
|
213
|
-
```
|
|
257
|
+
See `generators.md`.
|
|
214
258
|
|
|
215
|
-
|
|
259
|
+
### Doctor / Inspect v2
|
|
216
260
|
|
|
217
|
-
-
|
|
218
|
-
- forwarding headers are sanitized when trust is disabled,
|
|
219
|
-
- enable trust only behind a trusted reverse proxy/load balancer,
|
|
220
|
-
- Docker/process-manager `SIGTERM` triggers graceful shutdown,
|
|
221
|
-
- shutdown hooks are process-lifetime resource cleanup, not request cleanup,
|
|
222
|
-
- shutdown force-closes remaining public connections after the configured timeout.
|
|
261
|
+
Doctor adds deployment/project-health checks without removing previous checks. Inspect keeps its previous JSON fields and adds a `project` object containing lockfile, package manager, project metadata/presets, build presence, Dockerfile, framework declarations, storage provider and hardening status.
|
|
223
262
|
|
|
224
|
-
See `
|
|
263
|
+
See `developer-tools.md`.
|
|
225
264
|
|
|
226
|
-
###
|
|
265
|
+
### Project metadata
|
|
227
266
|
|
|
228
|
-
`create-bcp-app
|
|
267
|
+
New `create-bcp-app` projects receive:
|
|
229
268
|
|
|
230
269
|
```text
|
|
231
|
-
|
|
232
|
-
storage/
|
|
233
|
-
├─ .gitkeep
|
|
234
|
-
└─ README.md
|
|
270
|
+
bcp.project.json
|
|
235
271
|
```
|
|
236
272
|
|
|
237
|
-
|
|
273
|
+
The file records scaffold choices only and must never contain credentials/secrets.
|
|
274
|
+
|
|
275
|
+
See `project-metadata.md`.
|
|
276
|
+
|
|
277
|
+
### Docs-web contract
|
|
238
278
|
|
|
239
|
-
|
|
279
|
+
`docs/docs-web-manifest.json` is intended to be consumed directly by `bcp-docs-web` for navigation and route generation.
|
|
240
280
|
|
|
241
|
-
The
|
|
281
|
+
The website should still read the Markdown source referenced by each manifest page entry.
|
|
242
282
|
|
|
243
283
|
## CLI commands
|
|
244
284
|
|
|
@@ -247,6 +287,10 @@ bcp dev
|
|
|
247
287
|
bcp routes
|
|
248
288
|
bcp build
|
|
249
289
|
bcp start
|
|
290
|
+
bcp generate page dashboard/users
|
|
291
|
+
bcp generate api users
|
|
292
|
+
bcp generate middleware
|
|
293
|
+
bcp generate migration create_users
|
|
250
294
|
bcp doctor
|
|
251
295
|
bcp doctor --json
|
|
252
296
|
bcp inspect
|
|
@@ -265,6 +309,7 @@ On Windows, direct project-local commands should prefer:
|
|
|
265
309
|
```powershell
|
|
266
310
|
npm exec -- bcp-framework doctor
|
|
267
311
|
npm exec -- bcp-framework inspect
|
|
312
|
+
npm exec -- bcp-framework generate page dashboard/users
|
|
268
313
|
npm exec -- bcp-framework dev
|
|
269
314
|
npm exec -- bcp-framework build
|
|
270
315
|
```
|
|
@@ -279,9 +324,10 @@ Release notes live under:
|
|
|
279
324
|
docs/releases/
|
|
280
325
|
```
|
|
281
326
|
|
|
282
|
-
|
|
327
|
+
The docs-web manifest currently maps:
|
|
283
328
|
|
|
284
329
|
```text
|
|
330
|
+
/releases/0.1.29
|
|
285
331
|
/releases/0.1.28
|
|
286
332
|
/releases/0.1.27
|
|
287
333
|
/releases/0.1.26
|
|
@@ -299,25 +345,49 @@ unreleased development target
|
|
|
299
345
|
|
|
300
346
|
The existence of a release note alone does not mean the npm version is published.
|
|
301
347
|
|
|
302
|
-
## Suggested
|
|
348
|
+
## Suggested docs-web implementation
|
|
349
|
+
|
|
350
|
+
A simple implementation can model the manifest like:
|
|
303
351
|
|
|
304
352
|
```ts
|
|
305
|
-
interface
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
353
|
+
interface DocsWebManifest {
|
|
354
|
+
schemaVersion: number;
|
|
355
|
+
framework: string;
|
|
356
|
+
versionTarget: string;
|
|
357
|
+
releaseState: string;
|
|
358
|
+
sections: Array<{
|
|
359
|
+
id: string;
|
|
360
|
+
title: string;
|
|
361
|
+
pages: Array<{
|
|
362
|
+
route: string;
|
|
363
|
+
source: string;
|
|
364
|
+
title: string;
|
|
365
|
+
}>;
|
|
366
|
+
}>;
|
|
367
|
+
releases: Array<{
|
|
368
|
+
route: string;
|
|
369
|
+
source: string;
|
|
370
|
+
version: string;
|
|
371
|
+
state?: string;
|
|
372
|
+
}>;
|
|
315
373
|
}
|
|
316
374
|
```
|
|
317
375
|
|
|
376
|
+
Recommended website behavior:
|
|
377
|
+
|
|
378
|
+
1. Load/validate `docs-web-manifest.json` at build/startup.
|
|
379
|
+
2. Build the sidebar in manifest order.
|
|
380
|
+
3. Resolve each route to its referenced Markdown source.
|
|
381
|
+
4. Generate previous/next links from manifest order.
|
|
382
|
+
5. Index rendered Markdown headings/content for search.
|
|
383
|
+
6. Use `versionTarget` / `releaseState` for the site banner.
|
|
384
|
+
7. Use release entries for the release navigation.
|
|
385
|
+
|
|
386
|
+
Do not expose `bcp.project.json` secrets because the project metadata format is intentionally non-secret; runtime `.env` files should never be ingested into public docs output.
|
|
387
|
+
|
|
318
388
|
## Suggested website features
|
|
319
389
|
|
|
320
|
-
1. Sidebar
|
|
390
|
+
1. Sidebar from `docs-web-manifest.json`.
|
|
321
391
|
2. Markdown rendering + syntax highlighting.
|
|
322
392
|
3. Previous/next navigation.
|
|
323
393
|
4. Version/release-state banner.
|
|
@@ -359,35 +429,48 @@ npm run test:package
|
|
|
359
429
|
npm run rc:check
|
|
360
430
|
```
|
|
361
431
|
|
|
362
|
-
For `0.1.
|
|
432
|
+
For `0.1.29`, validation should cover project generators, Doctor/Inspect v2, create-app project metadata, the existing production hardening runtime and package preparation.
|
|
363
433
|
|
|
364
|
-
|
|
434
|
+
The release lockfile must be synchronized to `0.1.29` before the final tag.
|
|
365
435
|
|
|
366
436
|
## Documentation QA checklist
|
|
367
437
|
|
|
368
|
-
-
|
|
369
|
-
-
|
|
438
|
+
- every manifest Markdown source exists,
|
|
439
|
+
- every manifest route is unique,
|
|
440
|
+
- examples use public exports/CLI commands,
|
|
370
441
|
- version/release states are current,
|
|
371
442
|
- Windows direct CLI examples use `npm exec -- bcp-framework`,
|
|
372
443
|
- upload/storage/auth security caveats are present,
|
|
373
444
|
- release notes match the framework version,
|
|
374
445
|
- S3 credentials are never shown as public browser variables,
|
|
375
|
-
-
|
|
376
|
-
- proxy trust
|
|
377
|
-
- roadmap APIs are not presented as
|
|
446
|
+
- project metadata remains non-secret,
|
|
447
|
+
- proxy trust remains documented as opt-in,
|
|
448
|
+
- roadmap APIs are not presented as release guarantees.
|
|
378
449
|
|
|
379
|
-
## Next direction after 0.1.
|
|
450
|
+
## Next direction after 0.1.29
|
|
380
451
|
|
|
381
|
-
Planned
|
|
452
|
+
Planned **`0.2.0 — Framework Platform`** focus:
|
|
382
453
|
|
|
383
|
-
-
|
|
384
|
-
-
|
|
385
|
-
-
|
|
386
|
-
-
|
|
387
|
-
-
|
|
454
|
+
- consolidate public API naming/behavior,
|
|
455
|
+
- document compatibility expectations,
|
|
456
|
+
- stabilize supported production deployment paths,
|
|
457
|
+
- complete docs-web integration and documentation coverage,
|
|
458
|
+
- publish migration guidance for pre-`0.2.0` applications,
|
|
459
|
+
- establish a platform baseline before broader feature expansion.
|
|
388
460
|
|
|
389
|
-
These remain roadmap
|
|
461
|
+
These remain roadmap goals until their source/tests land.
|
|
390
462
|
|
|
391
463
|
## Repository authority
|
|
392
464
|
|
|
393
|
-
The framework repository remains authoritative for
|
|
465
|
+
The framework repository remains authoritative for:
|
|
466
|
+
|
|
467
|
+
```text
|
|
468
|
+
source
|
|
469
|
+
public exports
|
|
470
|
+
tests
|
|
471
|
+
Markdown docs
|
|
472
|
+
docs-web manifest
|
|
473
|
+
release notes
|
|
474
|
+
```
|
|
475
|
+
|
|
476
|
+
`bcp-docs-web` is the presentation/search/navigation layer for this content.
|