Repository navigation
chore(deps): upgrade markdown packages to 2.0.0, concerto-codegen to 7.1.0 and cicero-core to 3.0.0 - #206
Conversation
|
@mttrbrts the template-engine bump is up: #206 . It moves markdown-common, -template and -transform (and the markdown-html dev dependency) to ^2.0.0, with no source changes and no snapshot changes. The UMD drops from 9.95 MB to 5.86 MB (1.53 MB gzipped), since webpack now picks up markdown 2.0's ES modules. cicero-core ^2.2.0 still pulls markdown 1.x until its own bump is released, so template-playground#981 still waits on both. |
| @@ -50,9 +50,9 @@ | |||
There was a problem hiding this comment.
Let's hold this PR until cicero-core is released. Also, we should upgrade concerto-codegen at the same time.
|
Done: concerto-codegen is now ^7.1.0 here (one lockfile entry; webpack bundles it from dist/esm-browser and it shares the single concerto-core). Holding until cicero-core is released with template-archive#951, then I'll add that bump. That also collapses the three nested copies of markdown-cicero 2.0 that the current cicero-core forces. |
@ujjwalv01 cicero-core@2.3.0 is now released. Thanks! |
|
@mttrbrts , all three upgrades are in now: markdown 2.0, concerto-codegen 7.1 and cicero-core 2.3. With cicero-core 2.3, |
|
@mttrbrts cicero-core 3.0.0 is out now too. Would you like this PR on |
Let's do 3.0.0 here too, please |
Refs accordproject#185 Signed-off-by: Ujjwal Verma <ujjwalverma010305@gmail.com>
Refs accordproject#185 Signed-off-by: Ujjwal Verma <ujjwalverma010305@gmail.com>
cicero-core 2.3.0 depends on markdown ^2.0.0, so npm installs a single 2.0.0 copy of every markdown package. Refs accordproject#185 Signed-off-by: Ujjwal Verma <ujjwalverma010305@gmail.com>
Head branch was pushed to by a user without write access
44d4f60 to
75d05f7
Compare
cicero-core 3.0 only loads templates whose accordproject.cicero range includes its version, so the test archives now target ^3.0.0. Refs accordproject#185 Signed-off-by: Ujjwal Verma <ujjwalverma010305@gmail.com>
|
@mttrbrts cicero-core is now on 3.0.0 here, and the branch is rebased on One thing to flag: cicero-core 3.0 rejects templates whose Could you take another look? UPD : Docs PR for the cicero range check: accordproject/template-archive#956 |
Description
Part of #185 (section 2), as requested in #185 (comment) and in review.
Upgrades the dependencies whose new releases have landed:
@accordproject/markdown-common^1.1.0→^2.0.0@accordproject/markdown-template^1.1.0→^2.0.0@accordproject/markdown-transform^1.1.0→^2.0.0@accordproject/markdown-html(dev dependency)^1.1.0→^2.0.0@accordproject/concerto-codegen^6.3.0→^7.1.0@accordproject/cicero-core^2.2.0→^3.0.0: 2.3.0 first (chore(deps): bump markdown packages to ^2.0.0 in cicero-core template-archive#951, markdown^2.0.0), then 3.0.0 ( feat(cicero-core)!: publish ES module builds with an exports map and drop the UMD bundle template-archive#954, ES module builds and anexportsmap)This is only the version bumps. No source changes were needed: template-engine imports these packages only through their root entry points (
CodeGenandCommonfrom codegen, the markdown classes and models, and theTemplateandScripttypes from cicero-core), which the newexportsmaps keep. #207 removed the last deep cicero-core import. Switching to named ESM imports and template-engine's own ESM/exportswork come in a later PR.The lockfile changes only these packages and what they bring in or drop:
@noble/hashes(a new dependency ofmarkdown-template2.0);markdown-cicero/markdown-it-cicero2.0.0 copies with their pinnedsemver) and moves the top-levelmarkdown-ciceroandmarkdown-it-ciceroto 2.0.0;buffer,@noble/hashes) were already installed.npm lsnow shows a single 2.0.0 copy of every markdown package and a singleconcerto-core, deduplicated under cicero-core, and the lockfile holds one copy of every@accordprojectpackage.Commits
chore(deps): upgrade markdown packages to 2.0.0:package.jsonandpackage-lock.json.chore(deps): upgrade concerto-codegen to 7.1.0:package.jsonandpackage-lock.json.chore(deps): upgrade cicero-core to 2.3.0:package.jsonandpackage-lock.json.chore(deps): upgrade cicero-core to 3.0.0:package.json,package-lock.json, and theaccordproject.cicerorange of the three test archives (^2.0.0→^3.0.0), which cicero-core 3.0 would otherwise refuse to load.Compatibility
Template typing. markdown 2.0 includes fix(markdown-template): preserve parent scope in conditional and optional blocks markdown-transform#683 and #684. Variables inside
{{#if}}blocks, inside primitive and enum{{#optional}}blocks, and in their{{else}}branches now type-check against the parent scope, where they used to fail withUnknown property(Cannot use variables inside an #if block template-playground#2). This only accepts templates that were rejected before. No snapshots changed: the test templates use variables only in blocks that already worked ({{#optional loyaltyStatus}}{{level}}on a concept,{{this}}in{{#optional age}}), and their{{#if}}bodies and{{else}}branches contain no variables.Browser bundle. webpack now resolves the markdown packages and codegen through their
browserconditions to ES modules (lib/esm-browser,dist/esm-browser) instead of nested UMD bundles. Codegen's browser build importsconcerto-core,concerto-utilandconcerto-vocabularyas bare dependencies, so it shares template-engine's single copy instead of bundling its own. webpack stats show one package root each for codegen and the three Concerto packages.Templates must target cicero 3. cicero-core checks that its version satisfies the template's
accordproject.cicerorange, so with 3.0.0 a template declaring^2.0.0fails to load (The template targets Cicero version ^2.0.0 but the current Cicero version is 3.0.0.). The three test archives now declare^3.0.0. Templates used with this template-engine release need the same change.cicero-core is not in the UMD. template-engine imports only the
TemplateandScripttypes from cicero-core, so tsc drops the import and webpack stats show no cicero-core module, before and after the 3.0 bump. The UMD size is unchanged by it.One copy of each markdown package. With
cicero-core@^2.2.0, markdown 1.1.0 held the top ofnode_modules, so npm nestedmarkdown-ciceroandmarkdown-it-cicero2.0.0 under each ofmarkdown-template,markdown-transformandmarkdown-html, and the UMD bundled them three times. With 2.3.0, webpack stats show a single package root, at 2.0.0, for every markdown package. The bundled source shrinks by about 90 kB, but webpack had already tree-shaken most of the duplicated code, so the minified UMD stays at 5.36 MB (1.40 MB gzipped). The gain is a deduplicated install and a single markdown version for consumers, which unblocks template-playground#981.Testing
jest --ci(snapshots are compared, not written): 19/19 suites, 182/182 tests, 46/46 snapshots pass, with no snapshot changes. (Run in parallel with the e2e suite, someTemplateArchiveProcessorandTemplateMarkInterpretertests hit their timeouts; those suites pass on their own.)npm run licchkandnpm run lint: 0 errors. Lint's 8 warnings are already onmain, in generated files.npm run build:dist: TypeScript and the webpack UMD build complete.npx playwright test --config e2e/playwright.config.ts: 6/6 Chromium tests pass.🤖 Generated with Claude Code