An open source design system that's fully customizable and agent ready
TypeScript
ci: typecheck every package through pnpm typecheck (#8390)
Cindy Zhang4bcd84ff0742
diff --git a/.github/scripts/ci-native-typecheck.test.mjs b/.github/scripts/ci-native-typecheck.test.mjsindex 096b9e8041..54ce032628 100644--- a/.github/scripts/ci-native-typecheck.test.mjs+++ b/.github/scripts/ci-native-typecheck.test.mjs@@ -5,9 +5,9 @@** The native package is outside the root `pnpm build`, and Vitest neither* typechecks its source nor loads the declaration file of every platform- * condition. The `typecheck` job is the only gate over both, so it must run- * the package's typecheck, its build, and the check of the emitted platform- * types, in that order.+ * condition. The `typecheck` job is the only gate over both: its+ * `pnpm typecheck` runs native's own `typecheck` script, which checks the+ * package, builds it, and checks the emitted platform types, in that order.*/import fs from 'node:fs';@@ -30,22 +30,27 @@ const tsconfigTypes = JSON.parse(),);-const NATIVE_COMMANDS = [- 'pnpm -F @astryxdesign/native typecheck',- 'pnpm -F @astryxdesign/native build',- 'pnpm -F @astryxdesign/native typecheck:types',-];+const rootScripts = JSON.parse(+ fs.readFileSync(path.join(root, 'package.json'), 'utf8'),+).scripts;describe('native TypeScript checks', () => {- it('run in the typecheck job, after the root build, in order', () => {+ it('run in the typecheck job, after the root build', () => {const runs = ci.jobs.typecheck.steps.map(step => step.run?.trim() ?? '');- const indexes = NATIVE_COMMANDS.map(command => runs.indexOf(command));- for (const [i, index] of indexes.entries()) {- expect(index, NATIVE_COMMANDS[i]).toBeGreaterThan(- runs.indexOf('pnpm build'),- );- }- expect([...indexes].sort((a, b) => a - b)).toEqual(indexes);+ const build = runs.indexOf('pnpm build');+ const typecheck = runs.findIndex(run => /^\s*pnpm typecheck$/m.test(run));+ expect(build).toBeGreaterThan(-1);+ expect(typecheck).toBeGreaterThan(build);+ // `pnpm typecheck` runs every package's own typecheck; native is not+ // filtered out.+ expect(rootScripts.typecheck).toContain('run typecheck');+ expect(rootScripts.typecheck).not.toContain('@astryxdesign/native');+ });++ it("check the package, its build, and the emitted types, in that order", () => {+ expect(native.scripts.typecheck).toBe(+ 'tsc --project tsconfig.json --noEmit && pnpm build && pnpm typecheck:types',+ );});it('check every emitted platform declaration file', () => {diff --git a/.github/scripts/ci-test-routing.test.mjs b/.github/scripts/ci-test-routing.test.mjsindex d5cc531118..95b7a17729 100644--- a/.github/scripts/ci-test-routing.test.mjs+++ b/.github/scripts/ci-test-routing.test.mjs@@ -536,23 +536,55 @@ describe('full component typechecks', () => {// typecheck:docs covers only its .doc.mjs files, so a type error in a test// otherwise lands on main unseen (lab's MobileTokenizer.test.tsx did).const packages = ['core', 'lab', 'charts', 'richtext', 'vega'];+ const scriptsOf = dir => JSON.parse(read(`${dir}/package.json`)).scripts;it.each(['ci.yml', 'deploy.yml'])(- '%s typechecks every component package, tests included',+ '%s runs every package typecheck through pnpm typecheck',file => {const steps = load(file).jobs.typecheck.steps;- const command = name => `pnpm -F @astryxdesign/${name} typecheck`;- const core = steps.find(step => step.run === command('core'));- for (const name of packages) {- const step = steps.find(candidate => candidate.run === command(name));- expect(step, `${file} does not typecheck ${name}`).toBeDefined();- // The same specialized-lane guard as core's (none in deploy.yml).- expect(step.if, `${file}: ${name} is not guarded like core`).toBe(- core.if,- );- }+ const step = steps.find(candidate =>+ /^\s*pnpm typecheck\s*$/m.test(candidate.run ?? ''),+ );+ expect(step, `${file} does not run pnpm typecheck`).toBeDefined();+ expect(scriptsOf('.').typecheck).toBe(+ 'pnpm -r --no-bail --workspace-concurrency=1 --if-present --filter "!@astryxdesign/docsite" --filter "!@astryxdesign/sandbox" run typecheck',+ );},);++ it.each(packages)(+ "%s's typecheck covers its sources, tests, and docs",+ name => {+ const {typecheck, 'typecheck:docs': docs} = scriptsOf(`packages/${name}`);+ expect(docs).toBe('tsc --project tsconfig.docs.json');+ expect(typecheck).toMatch(+ /^tsc (--project tsconfig\.json )?--noEmit && pnpm typecheck:docs$/,+ );+ },+ );++ it('covers the CLI template docs and strict checkJs', () => {+ expect(scriptsOf('packages/cli').typecheck).toBe(+ 'pnpm typecheck:template-docs && pnpm typecheck:strict',+ );+ });++ it('keeps the previous list for a head that predates pnpm typecheck', () => {+ const step = load('ci.yml').jobs.typecheck.steps.find(+ candidate => candidate.name === 'Typecheck every package',+ );+ expect(step.env.WORKFLOW_SHA).toBe('${{ github.sha }}');+ expect(step.run).toContain(+ 'git show "$WORKFLOW_SHA:.github/scripts/typecheck-predating-head.sh" > "$legacy"',+ );+ const legacy = read('.github/scripts/typecheck-predating-head.sh');+ for (const name of packages) {+ expect(legacy).toContain(`pnpm -F @astryxdesign/${name} typecheck\n`);+ expect(legacy).toContain(+ `pnpm -F @astryxdesign/${name} typecheck:docs\n`,+ );+ }+ });});describe('deploy.yml push gating', () => {@@ -578,7 +610,7 @@ describe('deploy.yml push gating', () => {// build has to precede the gates in the SAME lane.const steps = workflow.jobs.typecheck.steps.map(step => step.run ?? '');const build = steps.findIndex(step => step.trim() === 'pnpm build');- const strict = steps.findIndex(step => step.includes('typecheck:strict'));+ const strict = steps.findIndex(step => /^pnpm typecheck$/m.test(step));expect(build).toBeGreaterThanOrEqual(0);expect(strict).toBeGreaterThan(build);@@ -588,17 +620,19 @@ describe('deploy.yml push gating', () => {// These exist because a typecheck error can otherwise land on main and// break the `build` check on every open PR (#3197).const gates = runLines(workflow.jobs.typecheck);- for (const gate of [- 'scripts/verify-exports.mjs',- '@astryxdesign/core typecheck:docs',- '@astryxdesign/lab typecheck:docs',- '@astryxdesign/charts typecheck:docs',- '@astryxdesign/cli typecheck:template-docs',- '@astryxdesign/cli typecheck:strict',- '@astryxdesign/storybook typecheck',- '@astryxdesign/core typecheck',+ expect(gates).toContain('scripts/verify-exports.mjs');+ expect(gates).toMatch(/^pnpm typecheck$/m);+ // Every package that guarded main still defines the script it reaches.+ for (const dir of [+ 'packages/core',+ 'packages/lab',+ 'packages/charts',+ 'packages/cli',+ 'apps/storybook',+ 'internal/a11y-spec',]) {- expect(gates, `lost the ${gate} gate`).toContain(gate);+ const {typecheck} = JSON.parse(read(`${dir}/package.json`)).scripts;+ expect(typecheck, `${dir} lost its typecheck`).toBeTruthy();}});diff --git a/.github/scripts/typecheck-predating-head.sh b/.github/scripts/typecheck-predating-head.shnew file mode 100755index 0000000000..c516a95411--- /dev/null+++ b/.github/scripts/typecheck-predating-head.sh@@ -0,0 +1,34 @@+#!/usr/bin/env bash+# Copyright (c) Meta Platforms, Inc. and affiliates.+#+# The typecheck job's commands for a pull request head that predates the root+# `pnpm typecheck` script.+#+# The typecheck job checks out the PR head, while its steps come from the merge+# commit. A head cut before `pnpm typecheck` existed has no such script, and+# its packages' own `typecheck` scripts do not yet cover their docs, so+# `pnpm typecheck` there would either fail or check less than the job did.+# This runs the job's previous command list against that head instead. It is+# frozen: new checks go into a package's `typecheck` script, never here.+# Delete it once no open pull request predates `pnpm typecheck`.+#+# The job loads this from the merge commit, since such a head lacks it.+set -euo pipefail++pnpm -F @astryxdesign/core typecheck:docs+pnpm -F @astryxdesign/lab typecheck:docs+pnpm -F @astryxdesign/charts typecheck:docs+pnpm -F @astryxdesign/richtext typecheck:docs+pnpm -F @astryxdesign/vega typecheck:docs+pnpm -F @astryxdesign/cli typecheck:template-docs+pnpm -F @astryxdesign/cli typecheck:strict+pnpm -F @astryxdesign/storybook typecheck+pnpm -F @astryxdesign/core typecheck+pnpm -F @astryxdesign/lab typecheck+pnpm -F @astryxdesign/charts typecheck+pnpm -F @astryxdesign/richtext typecheck+pnpm -F @astryxdesign/vega typecheck+pnpm -F @astryxdesign/a11y-spec typecheck+pnpm -F @astryxdesign/native typecheck+pnpm -F @astryxdesign/native build+pnpm -F @astryxdesign/native typecheck:typesdiff --git a/.github/workflows/ci.yml b/.github/workflows/ci.ymlindex 9d9a793742..2fbed8aa7e 100644--- a/.github/workflows/ci.yml+++ b/.github/workflows/ci.yml@@ -1193,85 +1193,25 @@ jobs:if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'run: pnpm build- - name: Typecheck component docs+ # Every workspace package's own `typecheck` script: its sources and+ # tests, its doc examples, and any declarations it emits. A new package+ # or tsconfig joins by defining or extending that script, not this job.+ # A PR head cut before `pnpm typecheck` existed runs the previous list,+ # loaded from the merge commit these steps come from.+ - name: Typecheck every packageif: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/core typecheck:docs-- - name: Typecheck lab docs- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/lab typecheck:docs-- - name: Typecheck charts docs- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/charts typecheck:docs-- - name: Typecheck rich text docs- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/richtext typecheck:docs-- - name: Typecheck Vega docs- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/vega typecheck:docs-- - name: Typecheck template docs- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/cli typecheck:template-docs-- # Full-package strict checkJs over the CLI (src, bin, scripts, docs, and- # the emitted templates). Requires the `pnpm build` above so the template- # .tsx sources can resolve the built @astryxdesign/{core,charts,lab} types.- - name: Typecheck CLI (strict)- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/cli typecheck:strict-- - name: Typecheck storybook- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/storybook typecheck-- - name: Typecheck core (including tests)- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/core typecheck-- # The other component packages' own sources and tests, like core's: their- # typecheck:docs steps above cover only their .doc.mjs files.- - name: Typecheck lab (including tests)- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/lab typecheck-- - name: Typecheck charts (including tests)- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/charts typecheck-- - name: Typecheck rich text (including tests)- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/richtext typecheck-- - name: Typecheck Vega (including tests)- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/vega typecheck-- # The accessibility spec-test contracts are consumed as TypeScript source- # by Vitest and Playwright, and neither runner typechecks. This is the- # only gate over them.- - name: Typecheck accessibility spec-test contracts- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/a11y-spec typecheck-- # The canary-only @astryxdesign/native is outside the root build, and- # Vitest neither typechecks its source nor loads every platform's types.- # Its build emits one declaration file per type-resolution condition- # (ios, android, macos, windows, shared); the last step checks them all.- - name: Typecheck native- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/native typecheck-- - name: Build native platform types- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/native build-- - name: Typecheck native platform types- if: needs.check-scope.outputs.docsite_only != 'true' && needs.check-scope.outputs.spec_only != 'true' && needs.check-scope.outputs.tooling_only != 'true'- run: pnpm -F @astryxdesign/native typecheck:types+ env:+ WORKFLOW_SHA: ${{ github.sha }}+ run: |+ if node -e "process.exit(require('./package.json').scripts?.typecheck ? 0 : 1)"; then+ pnpm typecheck+ else+ echo "::notice title=Head predates pnpm typecheck::Running the previous typecheck list; merge main to use pnpm typecheck."+ legacy="$RUNNER_TEMP/typecheck-predating-head.sh"+ git fetch --quiet --no-tags --depth=1 origin "$WORKFLOW_SHA"+ git show "$WORKFLOW_SHA:.github/scripts/typecheck-predating-head.sh" > "$legacy"+ bash "$legacy"+ fi# Sandbox preview build — the single slowest piece of PR CI (~4min), run as# its own job so it overlaps build-storybook instead of serializing after it.diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.ymlindex 698440caaf..2e92172d01 100644--- a/.github/workflows/deploy.yml+++ b/.github/workflows/deploy.yml@@ -31,14 +31,14 @@ jobs:# The push gate, as three parallel lanes joined by `test` below.## This was one job running both Vitest projects, a full `pnpm build`, and- # eight typecheck gates on a 2-core runner — strictly more than ci.yml's+ # every package typecheck on a 2-core runner — strictly more than ci.yml's# `test`, which was already being terminated around 20 minutes with no# summary. Same defect, later surface: main's post-merge gate was over the# same budget.## Nothing is dropped and nothing runs twice. The two Vitest projects are# independent by construction (vitest.config.ts), so they split cleanly; the- # typecheck gates need the `pnpm build` they follow, so they stay together in+ # typecheck needs the `pnpm build` it follows, so they stay together in# their own lane and take the build with them.## `ui` is the heavier project by ~4x here, so it takes the larger runner (see@@ -75,7 +75,7 @@ jobs:- run: pnpm vitest run --project node- # Typecheck gates mirroring the PR `build` job in ci.yml. ci.yml only runs+ # The typecheck mirroring the PR `build` job in ci.yml. ci.yml only runs# on pull_request/merge_group, so a typecheck error can land on main (its# push only runs the suite) undetected — then break the `build` check on# every open PR, which typechecks the PR merged with main (see #3197).@@ -96,55 +96,9 @@ jobs:- name: Verify package exportsrun: node scripts/verify-exports.mjs- - name: Typecheck component docs- run: pnpm -F @astryxdesign/core typecheck:docs-- - name: Typecheck lab docs- run: pnpm -F @astryxdesign/lab typecheck:docs-- - name: Typecheck charts docs- run: pnpm -F @astryxdesign/charts typecheck:docs-- - name: Typecheck rich text docs- run: pnpm -F @astryxdesign/richtext typecheck:docs-- - name: Typecheck Vega docs- run: pnpm -F @astryxdesign/vega typecheck:docs-- - name: Typecheck template docs- run: pnpm -F @astryxdesign/cli typecheck:template-docs-- # Full-package strict checkJs over the CLI (src, bin, scripts, docs, and- # the emitted templates). Requires the `pnpm build` above so the template- # .tsx sources can resolve the built @astryxdesign/{core,charts,lab} types.- - name: Typecheck CLI (strict)- run: pnpm -F @astryxdesign/cli typecheck:strict-- - name: Typecheck storybook- run: pnpm -F @astryxdesign/storybook typecheck-- - name: Typecheck core (including tests)- run: pnpm -F @astryxdesign/core typecheck-- # The other component packages' own sources and tests, like core's: their- # typecheck:docs gates above cover only their .doc.mjs files.- - name: Typecheck lab (including tests)- run: pnpm -F @astryxdesign/lab typecheck-- - name: Typecheck charts (including tests)- run: pnpm -F @astryxdesign/charts typecheck-- - name: Typecheck rich text (including tests)- run: pnpm -F @astryxdesign/richtext typecheck-- - name: Typecheck Vega (including tests)- run: pnpm -F @astryxdesign/vega typecheck-- # The accessibility spec-test contracts are consumed as TypeScript source- # by Vitest and Playwright, and neither runner typechecks. This is the- # only gate over them.- - name: Typecheck accessibility spec-test contracts- run: pnpm -F @astryxdesign/a11y-spec typecheck+ # Every workspace package's own `typecheck` script, as in ci.yml.+ - name: Typecheck every package+ run: pnpm typecheck# Stable join for the three post-merge validation lanes.test:diff --git a/CONTRIBUTING.md b/CONTRIBUTING.mdindex 70749bdd90..282d1e3f7a 100644--- a/CONTRIBUTING.md+++ b/CONTRIBUTING.md@@ -171,6 +171,7 @@ astryx/| `pnpm build` | Build all packages || `pnpm test` | Run all tests || `pnpm test:watch` | Run tests in watch mode |+| `pnpm typecheck` | Typecheck every package (after `pnpm build`) || `pnpm storybook` | Start Storybook at localhost:6006 || `pnpm lint` | Lint all packages |diff --git a/package.json b/package.jsonindex 9052c34ad0..e8a522cce2 100644--- a/package.json+++ b/package.json@@ -25,6 +25,7 @@"test:coverage": "vitest --coverage","test:a11y-contract": "playwright test --config playwright.config.ts --project chromium","test:docsite-browser": "playwright test --config apps/docsite/playwright.config.ts",+ "typecheck": "pnpm -r --no-bail --workspace-concurrency=1 --if-present --filter \"!@astryxdesign/docsite\" --filter \"!@astryxdesign/sandbox\" run typecheck","check:package-boundaries": "node scripts/check-package-boundaries.js","check:repo": "pnpm check:visual-owner && pnpm check:sync && pnpm check:neutral-palette-refs && pnpm check:stone-palette-refs && pnpm check:gothic-palette-refs && pnpm check:matcha-palette-refs && pnpm check:butter-palette-refs && pnpm check:y2k-palette-refs && pnpm check:data-tokens && pnpm check:token-docs && pnpm check:knowledge && pnpm check:package-boundaries && pnpm check:changesets && pnpm check:demo-media && pnpm check:executable-bits && pnpm check:cli-structure && pnpm check:use-client && pnpm check:portable-scripts && pnpm check:i18n-runtime && pnpm check:i18n-catalog && pnpm check:cldr-weekdays && pnpm check:fixtures && pnpm check:setup-contract","check:visual-owner": "node scripts/check-visual-workflow-owner.mjs",diff --git a/packages/charts/package.json b/packages/charts/package.jsonindex ddb32dc3ae..f3f318d437 100644--- a/packages/charts/package.json+++ b/packages/charts/package.json@@ -58,7 +58,7 @@"test:watch": "vitest --root ../..","lint": "eslint src","typecheck:docs": "tsc --project tsconfig.docs.json",- "typecheck": "tsc --project tsconfig.json --noEmit"+ "typecheck": "tsc --project tsconfig.json --noEmit && pnpm typecheck:docs"},"peerDependencies": {"@stylexjs/stylex": ">=0.10.0",diff --git a/packages/cli/package.json b/packages/cli/package.jsonindex 258a20be87..6709035ee0 100644--- a/packages/cli/package.json+++ b/packages/cli/package.json@@ -98,6 +98,7 @@"postinstall": "node scripts/postinstall.mjs","test": "cd ../.. && vitest run packages/cli","test:watch": "cd ../.. && vitest packages/cli",+ "typecheck": "pnpm typecheck:template-docs && pnpm typecheck:strict","typecheck:template-docs": "tsc --project tsconfig.template-docs.json","typecheck:json-api": "tsc --project tsconfig.json-api.json","typecheck:strict": "tsc --project tsconfig.strict.json",diff --git a/packages/core/package.json b/packages/core/package.jsonindex 8f02333465..6e9a4db109 100644--- a/packages/core/package.json+++ b/packages/core/package.json@@ -799,7 +799,7 @@"test:watch": "vitest --root ../..","lint": "eslint src","typecheck:docs": "tsc --project tsconfig.docs.json",- "typecheck": "tsc --project tsconfig.json --noEmit"+ "typecheck": "tsc --project tsconfig.json --noEmit && pnpm typecheck:docs"},"peerDependencies": {"@stylexjs/stylex": "^0.19.0",diff --git a/packages/lab/package.json b/packages/lab/package.jsonindex 12be91f693..2024aa530b 100644--- a/packages/lab/package.json+++ b/packages/lab/package.json@@ -58,7 +58,7 @@"test:watch": "vitest --root ../..","lint": "eslint src","typecheck:docs": "tsc --project tsconfig.docs.json",- "typecheck": "tsc --project tsconfig.json --noEmit",+ "typecheck": "tsc --project tsconfig.json --noEmit && pnpm typecheck:docs","generate:emoji-data": "node scripts/generate-emoji-data.mjs"},"peerDependencies": {diff --git a/packages/native/package.json b/packages/native/package.jsonindex 5dabc4ba62..f39c0f0dc7 100644--- a/packages/native/package.json+++ b/packages/native/package.json@@ -76,7 +76,7 @@"generate:apple": "pnpm build && node scripts/generate.mjs --apple","generate:swift-ios": "pnpm -F @astryxdesign/core build && node scripts/swift-ios-theme.mjs && node scripts/swift-ios-strings.mjs","test": "vitest run --root ../.. packages/native",- "typecheck": "tsc --project tsconfig.json --noEmit",+ "typecheck": "tsc --project tsconfig.json --noEmit && pnpm build && pnpm typecheck:types","typecheck:types": "tsc --project tsconfig.types.json"},"peerDependencies": {diff --git a/packages/richtext/package.json b/packages/richtext/package.jsonindex 16b45af5a8..29d1bc259b 100644--- a/packages/richtext/package.json+++ b/packages/richtext/package.json@@ -61,7 +61,7 @@"test:watch": "vitest --root ../..","lint": "eslint src","typecheck:docs": "tsc --project tsconfig.docs.json",- "typecheck": "tsc --project tsconfig.json --noEmit"+ "typecheck": "tsc --project tsconfig.json --noEmit && pnpm typecheck:docs"},"peerDependencies": {"@stylexjs/stylex": ">=0.10.0",diff --git a/packages/vega/package.json b/packages/vega/package.jsonindex 049cfa5c83..d996fc0585 100644--- a/packages/vega/package.json+++ b/packages/vega/package.json@@ -48,7 +48,7 @@"test": "vitest run --root ../..","test:watch": "vitest --root ../..","typecheck:docs": "tsc --project tsconfig.docs.json",- "typecheck": "tsc --noEmit"+ "typecheck": "tsc --noEmit && pnpm typecheck:docs"},"peerDependencies": {"react": ">=19.2.0",