@beignet/next 0.0.44 → 0.0.46

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/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # @beignet/next
2
2
 
3
+ ## 0.0.46
4
+
5
+ ### Patch Changes
6
+
7
+ - @beignet/web@0.0.46
8
+
9
+ ## 0.0.45
10
+
11
+ ### Patch Changes
12
+
13
+ - b9df150: Declare client-component boundaries for hook entrypoints and document Swagger UI deployment constraints.
14
+ - @beignet/web@0.0.45
15
+
3
16
  ## 0.0.44
4
17
 
5
18
  ### Patch Changes
package/README.md CHANGED
@@ -575,6 +575,15 @@ export const GET = createSwaggerUIHandler({
575
575
  });
576
576
  ```
577
577
 
578
+ The built-in HTML loads version-pinned Swagger UI assets from `unpkg.com` with
579
+ subresource-integrity checks. Apps with a strict Content Security Policy or no
580
+ public CDN access should serve a custom, self-hosted documentation UI instead
581
+ of this convenience handler. Using the built-in page requires policy allowances
582
+ for the pinned asset host and its emitted inline script and style blocks;
583
+ allowing `unpkg.com` alone is not sufficient.
584
+ Protect the OpenAPI and documentation routes with app-owned authorization when
585
+ enumerating the route surface is sensitive.
586
+
578
587
  ## Public storage routes
579
588
 
580
589
  Use `createStorageRoute` to serve public objects from a `StoragePort` in a
@@ -1184,6 +1193,11 @@ by the runtime without booting providers during route-module import.
1184
1193
  ### `createSwaggerUIHandler(options?): (req: Request) => Response`
1185
1194
 
1186
1195
  Creates a Next.js route handler that serves Swagger UI for an OpenAPI endpoint.
1196
+ Its generated HTML loads version-pinned assets from `unpkg.com` with
1197
+ subresource-integrity checks and emits inline script and style blocks.
1198
+ Strict-CSP or network-isolated deployments should self-host a custom
1199
+ CSP-compatible UI. Allowing the asset host alone does not make the convenience
1200
+ handler compatible with a strict policy.
1187
1201
 
1188
1202
  ### `createWebhookRoute(options): { POST }`
1189
1203
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@beignet/next",
3
- "version": "0.0.44",
3
+ "version": "0.0.46",
4
4
  "type": "module",
5
5
  "description": "Next.js server-side handlers for Beignet",
6
6
  "main": "./dist/index.js",
@@ -61,7 +61,7 @@
61
61
  "next": "^14.0.0 || ^15.0.0 || ^16.0.0"
62
62
  },
63
63
  "dependencies": {
64
- "@beignet/web": "^0.0.44",
64
+ "@beignet/web": "^0.0.46",
65
65
  "@standard-schema/spec": "^1.0.0"
66
66
  },
67
67
  "devDependencies": {
@@ -130,6 +130,13 @@ Prefer adapter helpers for focused surfaces when the package provides them:
130
130
  `createWebhookRoute(...)`, `createPaymentWebhookRoute(...)`,
131
131
  `createScheduleRoute(...)`, and `createOutboxDrainRoute(...)`.
132
132
 
133
+ OpenAPI documents enumerate protected routes as well as public ones, so add
134
+ app-owned authorization to spec and docs endpoints when that surface is
135
+ sensitive. `createSwaggerUIHandler(...)` loads version-pinned assets from
136
+ `unpkg.com` and emits inline script and style blocks; strict-CSP or
137
+ network-isolated deployments should use a custom self-hosted CSP-compatible UI.
138
+ Allowing the asset host alone is not sufficient.
139
+
133
140
  For Next.js 15.1 and newer, apps may also use
134
141
  `createNextOutboxDrainTrigger(...)` with `after()` and replace their database
135
142
  Unit of Work from `server/providers.ts` with a