@amboras-dev/storefront-core 2026.11.12-rc.1 → 2026.11.12
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 +3 -0
- package/bin/checks/check-market-routes.mjs +4 -1
- package/core-manifest.json +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -131,6 +131,9 @@
|
|
|
131
131
|
Vercel, where the two are equal.
|
|
132
132
|
- `edge/proxy.ts` no longer claims to be generated from the orchestrator's `middleware-template.ts`: core stores run
|
|
133
133
|
this file, legacy stores run the template.
|
|
134
|
+
- `amboras-check market-routes` requires `app/[m]/layout.*` to call `assertMarketKey(`, read with comments stripped
|
|
135
|
+
(the sibling gate's `stripComments`). It accepted any layout that named it, so one that kept the import but dropped
|
|
136
|
+
the call passed, and every page then rendered under a first segment no market owns (`/api/about` answered 200).
|
|
134
137
|
|
|
135
138
|
## 2026.11.11
|
|
136
139
|
|
|
@@ -22,6 +22,8 @@
|
|
|
22
22
|
import { existsSync, readdirSync, readFileSync, realpathSync } from 'node:fs'
|
|
23
23
|
import { dirname, join, relative, sep } from 'node:path'
|
|
24
24
|
import { fileURLToPath, pathToFileURL } from 'node:url'
|
|
25
|
+
// The sibling gate's comment stripper (inert on import: it runs its main() only as process.argv[1]).
|
|
26
|
+
import { stripComments } from './check-store-quirks.mjs'
|
|
25
27
|
|
|
26
28
|
const TAG = '[check-market-routes]'
|
|
27
29
|
const SCRIPT_EXT = '(?:tsx?|jsx?)'
|
|
@@ -51,7 +53,8 @@ export function layoutProblem(root) {
|
|
|
51
53
|
const dir = join(root, 'app', '[m]')
|
|
52
54
|
const layout = existsSync(dir) ? readdirSync(dir).find((name) => LAYOUT_RE.test(name)) : undefined
|
|
53
55
|
if (!layout) return 'app/[m]/layout.tsx is missing: it sets the market metadataBase and answers a bad key with assertMarketKey.'
|
|
54
|
-
|
|
56
|
+
// A call, not the name: the import line alone (or a call left in a comment) guards nothing.
|
|
57
|
+
if (!/\bassertMarketKey\s*\(/.test(stripComments(readFileSync(join(dir, layout), 'utf8')))) {
|
|
55
58
|
return `app/[m]/${layout} does not call assertMarketKey(m, notFound): a path no rewrite reaches (/api/missing.json) would render a page under any first segment.`
|
|
56
59
|
}
|
|
57
60
|
return null
|
package/core-manifest.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@amboras-dev/storefront-core",
|
|
3
|
-
"version": "2026.11.12
|
|
3
|
+
"version": "2026.11.12",
|
|
4
4
|
"description": "The platform half of every Amboras storefront: cart, checkout, payments, auth, orders, subscriptions, catalogue data, analytics, consent, plugin slots, edge proxy and the Next config. Stores keep only design; they import this. ESM, React 19, Next 16.",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"type": "module",
|