docs(examples): use plain vite for StackBlitz compatibility - #2958
Conversation
…patibility vite-plus requires platform-specific native NAPI-RS bindings that cannot run in StackBlitz's WebContainers environment, causing all example StackBlitz links to crash with "Cannot find native binding". The examples only use standard Vite features (defineConfig, dev server, build), so switching to plain vite resolves this without any functionality loss. - Update example templates to use vite instead of vite-plus - Change scripts from vp dev/build/preview to vite equivalents - Add vite ^8.0.0 to pnpm workspace catalog - Regenerate all example files
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
📝 WalkthroughWalkthroughChangesVite migration
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
@blocknote/ariakit
@blocknote/code-block
@blocknote/core
@blocknote/mantine
@blocknote/react
@blocknote/server-util
@blocknote/shadcn
@blocknote/xl-ai
@blocknote/xl-docx-exporter
@blocknote/xl-email-exporter
@blocknote/xl-multi-column
@blocknote/xl-odt-exporter
@blocknote/xl-pdf-exporter
commit: |
|
There was a problem hiding this comment.
Actionable comments posted: 13
🧹 Nitpick comments (3)
examples/01-basic/06-block-manipulation/package.json (2)
28-28: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winThe generated manifests do not clearly consume the new workspace catalog.
Each manifest hard-codes
^8.0.0; pnpm catalogs are referenced through thecatalog:protocol. Usecatalog:, or verify that the generator intentionally materializes literal ranges and checks them againstpnpm-workspace.yaml. (pnpm.io)
examples/01-basic/06-block-manipulation/package.json#L28-L28: consume the catalog or add a synchronization check.examples/01-basic/07-selection-blocks/package.json#L28-L28: consume the catalog or add a synchronization check.examples/05-interoperability/03-converting-blocks-to-md/package.json#L28-L28: consume the catalog or add a synchronization check.examples/05-interoperability/04-converting-blocks-from-md/package.json#L28-L28: consume the catalog or add a synchronization check.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@examples/01-basic/06-block-manipulation/package.json` at line 28, Update the vite dependency in package.json for examples/01-basic/06-block-manipulation/package.json:28-28, examples/01-basic/07-selection-blocks/package.json:28-28, examples/05-interoperability/03-converting-blocks-to-md/package.json:28-28, and examples/05-interoperability/04-converting-blocks-from-md/package.json:28-28 to consume the workspace catalog via the catalog: protocol, or add generator synchronization checks that validate each literal range against pnpm-workspace.yaml.
10-10: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winThe generated
build:prodscripts retain a type-check command forbidden by repository policy.Replace
tscwith the supported type-check command, or document an explicit exception for standalone examples.
examples/01-basic/06-block-manipulation/package.json#L10-L10: updatebuild:prod.examples/01-basic/07-selection-blocks/package.json#L10-L10: updatebuild:prod.examples/05-interoperability/03-converting-blocks-to-md/package.json#L10-L10: updatebuild:prod.examples/05-interoperability/04-converting-blocks-from-md/package.json#L10-L10: updatebuild:prod.As per coding guidelines: use
vp run lintfor linting and type-checking; do not usetscorprettier.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@examples/01-basic/06-block-manipulation/package.json` at line 10, Replace the tsc invocation in the build:prod script with the supported vp run lint command in examples/01-basic/06-block-manipulation/package.json:10-10, examples/01-basic/07-selection-blocks/package.json:10-10, examples/05-interoperability/03-converting-blocks-to-md/package.json:10-10, and examples/05-interoperability/04-converting-blocks-from-md/package.json:10-10; no exception documentation is needed.Source: Coding guidelines
examples/02-backend/01-file-uploading/package.json (1)
8-11: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winUse the repository-approved type-checking command across all standalone examples.
Each
build:prodscript invokestscdirectly. Move type-checking to the monorepovp run lintpath and keep the standalone build command asvite build.
examples/02-backend/01-file-uploading/package.json#L8-L11: replace the directtscinvocation.examples/02-backend/02-saving-loading/package.json#L8-L11: replace the directtscinvocation.examples/06-custom-schema/react-custom-styles/package.json#L8-L11: replace the directtscinvocation.examples/07-collaboration/01-partykit/package.json#L8-L11: replace the directtscinvocation.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@examples/02-backend/01-file-uploading/package.json` around lines 8 - 11, Update the build:prod script in all four listed package.json files to run the repository-approved vp run lint type-checking path before vite build, removing the direct tsc invocation. Keep the existing start, dev, and preview scripts unchanged, and apply the same script adjustment in each affected file.Source: Coding guidelines
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@examples/01-basic/01-minimal/package.json`:
- Line 10: Replace the build:prod script with vite build in
examples/01-basic/01-minimal/package.json (line 10),
examples/01-basic/02-block-objects/package.json (line 10),
examples/04-theming/03-theming-css/package.json (line 10), and
examples/04-theming/04-theming-css-variables/package.json (line 10), removing
direct tsc usage from all four manifests. Use vp run lint for linting and
type-checking instead of tsc or prettier.
In `@examples/01-basic/03-multi-column/package.json`:
- Line 10: Replace the direct tsc invocation in the build:prod script of
examples/01-basic/03-multi-column/package.json,
examples/04-theming/05-theming-css-variables-code/package.json,
examples/04-theming/06-code-block/package.json, and
examples/04-theming/07-custom-code-block/package.json with vp run lint before
vite build. If StackBlitz lacks vp, define and test an explicit exception.
In `@examples/01-basic/08-ariakit/package.json`:
- Line 10: Replace the direct tsc invocation in the build:prod script with vp
run lint in examples/01-basic/08-ariakit/package.json:10-10,
examples/05-interoperability/05-converting-blocks-to-pdf/package.json:10-10,
examples/05-interoperability/06-converting-blocks-to-docx/package.json:10-10,
and examples/05-interoperability/07-converting-blocks-to-odt/package.json:10-10,
preserving the existing Vite build step.
In `@examples/01-basic/14-editor-scrollable/package.json`:
- Line 10: Update the build:prod scripts to remove the direct tsc command and
use the repository’s vp task for type-checking while preserving the Vite build.
Apply this change in examples/01-basic/14-editor-scrollable/package.json:10-10,
examples/01-basic/15-shadowdom/package.json:10-10,
examples/06-custom-schema/05-alert-block-full-ux/package.json:10-10, and
examples/06-custom-schema/06-toggleable-blocks/package.json:10-10.
In `@examples/01-basic/testing/package.json`:
- Line 10: Remove direct tsc usage from the build:prod scripts in
examples/01-basic/testing/package.json:10,
examples/06-custom-schema/draggable-inline-content/package.json:10,
examples/06-custom-schema/react-custom-blocks/package.json:10, and
examples/06-custom-schema/react-custom-inline-content/package.json:10. Replace
or remove the tsc invocation while preserving the Vite production build, and use
vp run lint for type-checking and linting in accordance with repository
guidelines.
In `@examples/03-ui-components/01-ui-elements-remove/package.json`:
- Line 10: Update the build:prod scripts to use the repository-approved vp run
lint flow instead of tsc in
examples/03-ui-components/01-ui-elements-remove/package.json:10-10,
examples/07-collaboration/04-electric-sql/package.json:10-10,
examples/07-collaboration/05-comments/package.json:10-10, and
examples/07-collaboration/06-comments-with-sidebar/package.json:10-10; do not
use tsc or prettier, and document an explicit exemption only if an example
cannot use the approved command.
In `@examples/03-ui-components/04-side-menu-buttons/package.json`:
- Around line 8-11: Update the start, dev, and build:prod scripts in all four
listed package.json files: replace bare vite commands with pnpm exec vite, and
replace tsc && vite build with vp run lint && pnpm exec vite build. Leave
preview unchanged.
In `@examples/03-ui-components/06-suggestion-menus-slash-menu-items/package.json`:
- Line 10: Remove the direct tsc invocation from the build:prod script in
examples/03-ui-components/06-suggestion-menus-slash-menu-items/package.json,
examples/07-collaboration/11-versioning-yjs13/package.json,
examples/07-collaboration/12-multi-doc-versioning/package.json, and
examples/07-collaboration/13-versioning-yjs14/package.json. Ensure generated
examples rely on the repository’s vp run lint workflow for linting and
type-checking.
In
`@examples/03-ui-components/07-suggestion-menus-slash-menu-component/package.json`:
- Line 10: The four build:prod scripts must use vp run lint instead of invoking
tsc directly. Update the generator responsible for these package scripts, then
regenerate all affected examples:
examples/03-ui-components/07-suggestion-menus-slash-menu-component/package.json
(anchor),
examples/03-ui-components/08-suggestion-menus-emoji-picker-columns/package.json,
examples/07-collaboration/14-suggestion-gallery/package.json, and
examples/08-extensions/01-tiptap-arrow-conversion/package.json; each site
requires the same build:prod command change.
In
`@examples/03-ui-components/09-suggestion-menus-emoji-picker-component/package.json`:
- Line 10: Update the build:prod script in
examples/03-ui-components/09-suggestion-menus-emoji-picker-component/package.json:10-10,
examples/03-ui-components/10-suggestion-menus-grid-mentions/package.json:10-10,
examples/08-extensions/02-versioning/package.json:10-10, and
examples/09-ai/01-minimal/package.json:10-10 to use vp build instead of tsc &&
vite build; leave type checking to vp run lint.
In `@examples/03-ui-components/12-static-formatting-toolbar/package.json`:
- Line 10: Replace the direct tsc invocation in the build:prod script with vp
run lint before vite build in all affected package files:
examples/03-ui-components/12-static-formatting-toolbar/package.json (anchor,
line 10), examples/03-ui-components/13-custom-ui/package.json (sibling, line
10), examples/09-ai/05-manual-execution/package.json (sibling, line 10), and
examples/09-ai/06-client-side-transport/package.json (sibling, line 10).
In `@examples/03-ui-components/16-link-toolbar-buttons/package.json`:
- Line 10: Remove the direct tsc invocation from the build:prod script in
examples/03-ui-components/16-link-toolbar-buttons/package.json (line 10),
examples/vanilla-js/react-vanilla-custom-inline-content/package.json (line 10),
examples/vanilla-js/react-vanilla-custom-styles/package.json (line 10), and
examples/vanilla-js/vanilla-custom-side-menu/package.json (line 10); keep
production builds using the approved workflow, with linting and type-checking
performed through vp run lint outside these standalone scripts.
In
`@examples/03-ui-components/19-suggestion-menus-grouping-ordering/package.json`:
- Line 10: Replace the direct tsc invocation in the build:prod scripts with vp
run lint across
examples/03-ui-components/19-suggestion-menus-grouping-ordering/package.json:10-10,
examples/03-ui-components/20-portal-elements/package.json:10-10,
examples/04-theming/01-theming-dom-attributes/package.json:10-10, and
examples/04-theming/02-changing-font/package.json:10-10. If vp cannot run
independently in these examples, remove type-checking from each build:prod
script so it runs only vite build, relying on monorepo validation for
type-checking.
---
Nitpick comments:
In `@examples/01-basic/06-block-manipulation/package.json`:
- Line 28: Update the vite dependency in package.json for
examples/01-basic/06-block-manipulation/package.json:28-28,
examples/01-basic/07-selection-blocks/package.json:28-28,
examples/05-interoperability/03-converting-blocks-to-md/package.json:28-28, and
examples/05-interoperability/04-converting-blocks-from-md/package.json:28-28 to
consume the workspace catalog via the catalog: protocol, or add generator
synchronization checks that validate each literal range against
pnpm-workspace.yaml.
- Line 10: Replace the tsc invocation in the build:prod script with the
supported vp run lint command in
examples/01-basic/06-block-manipulation/package.json:10-10,
examples/01-basic/07-selection-blocks/package.json:10-10,
examples/05-interoperability/03-converting-blocks-to-md/package.json:10-10, and
examples/05-interoperability/04-converting-blocks-from-md/package.json:10-10; no
exception documentation is needed.
In `@examples/02-backend/01-file-uploading/package.json`:
- Around line 8-11: Update the build:prod script in all four listed package.json
files to run the repository-approved vp run lint type-checking path before vite
build, removing the direct tsc invocation. Keep the existing start, dev, and
preview scripts unchanged, and apply the same script adjustment in each affected
file.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro Plus
Run ID: bb4f16c6-fef8-4fcd-8b01-f4e33aa2e6fa
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (298)
examples/01-basic/01-minimal/package.jsonexamples/01-basic/01-minimal/vite-env.d.tsexamples/01-basic/01-minimal/vite.config.tsexamples/01-basic/02-block-objects/package.jsonexamples/01-basic/02-block-objects/vite-env.d.tsexamples/01-basic/02-block-objects/vite.config.tsexamples/01-basic/03-multi-column/package.jsonexamples/01-basic/03-multi-column/vite-env.d.tsexamples/01-basic/03-multi-column/vite.config.tsexamples/01-basic/04-default-blocks/package.jsonexamples/01-basic/04-default-blocks/vite-env.d.tsexamples/01-basic/04-default-blocks/vite.config.tsexamples/01-basic/05-removing-default-blocks/package.jsonexamples/01-basic/05-removing-default-blocks/vite-env.d.tsexamples/01-basic/05-removing-default-blocks/vite.config.tsexamples/01-basic/06-block-manipulation/package.jsonexamples/01-basic/06-block-manipulation/vite-env.d.tsexamples/01-basic/06-block-manipulation/vite.config.tsexamples/01-basic/07-selection-blocks/package.jsonexamples/01-basic/07-selection-blocks/vite-env.d.tsexamples/01-basic/07-selection-blocks/vite.config.tsexamples/01-basic/08-ariakit/package.jsonexamples/01-basic/08-ariakit/vite-env.d.tsexamples/01-basic/08-ariakit/vite.config.tsexamples/01-basic/09-shadcn/package.jsonexamples/01-basic/09-shadcn/vite-env.d.tsexamples/01-basic/09-shadcn/vite.config.tsexamples/01-basic/10-localization/package.jsonexamples/01-basic/10-localization/vite-env.d.tsexamples/01-basic/10-localization/vite.config.tsexamples/01-basic/11-custom-placeholder/package.jsonexamples/01-basic/11-custom-placeholder/vite-env.d.tsexamples/01-basic/11-custom-placeholder/vite.config.tsexamples/01-basic/12-multi-editor/package.jsonexamples/01-basic/12-multi-editor/vite-env.d.tsexamples/01-basic/12-multi-editor/vite.config.tsexamples/01-basic/13-custom-paste-handler/package.jsonexamples/01-basic/13-custom-paste-handler/vite-env.d.tsexamples/01-basic/13-custom-paste-handler/vite.config.tsexamples/01-basic/14-editor-scrollable/package.jsonexamples/01-basic/14-editor-scrollable/vite-env.d.tsexamples/01-basic/14-editor-scrollable/vite.config.tsexamples/01-basic/15-shadowdom/package.jsonexamples/01-basic/15-shadowdom/vite-env.d.tsexamples/01-basic/15-shadowdom/vite.config.tsexamples/01-basic/16-read-only-editor/package.jsonexamples/01-basic/16-read-only-editor/vite-env.d.tsexamples/01-basic/16-read-only-editor/vite.config.tsexamples/01-basic/17-no-trailing-block/package.jsonexamples/01-basic/17-no-trailing-block/vite-env.d.tsexamples/01-basic/17-no-trailing-block/vite.config.tsexamples/01-basic/testing/package.jsonexamples/01-basic/testing/vite-env.d.tsexamples/01-basic/testing/vite.config.tsexamples/02-backend/01-file-uploading/package.jsonexamples/02-backend/01-file-uploading/vite-env.d.tsexamples/02-backend/01-file-uploading/vite.config.tsexamples/02-backend/02-saving-loading/package.jsonexamples/02-backend/02-saving-loading/vite-env.d.tsexamples/02-backend/02-saving-loading/vite.config.tsexamples/02-backend/03-s3/package.jsonexamples/02-backend/03-s3/vite-env.d.tsexamples/02-backend/03-s3/vite.config.tsexamples/02-backend/04-rendering-static-documents/package.jsonexamples/02-backend/04-rendering-static-documents/vite-env.d.tsexamples/02-backend/04-rendering-static-documents/vite.config.tsexamples/03-ui-components/01-ui-elements-remove/package.jsonexamples/03-ui-components/01-ui-elements-remove/vite-env.d.tsexamples/03-ui-components/01-ui-elements-remove/vite.config.tsexamples/03-ui-components/02-formatting-toolbar-buttons/package.jsonexamples/03-ui-components/02-formatting-toolbar-buttons/vite-env.d.tsexamples/03-ui-components/02-formatting-toolbar-buttons/vite.config.tsexamples/03-ui-components/03-formatting-toolbar-block-type-items/package.jsonexamples/03-ui-components/03-formatting-toolbar-block-type-items/vite-env.d.tsexamples/03-ui-components/03-formatting-toolbar-block-type-items/vite.config.tsexamples/03-ui-components/04-side-menu-buttons/package.jsonexamples/03-ui-components/04-side-menu-buttons/vite-env.d.tsexamples/03-ui-components/04-side-menu-buttons/vite.config.tsexamples/03-ui-components/05-side-menu-drag-handle-items/package.jsonexamples/03-ui-components/05-side-menu-drag-handle-items/vite-env.d.tsexamples/03-ui-components/05-side-menu-drag-handle-items/vite.config.tsexamples/03-ui-components/06-suggestion-menus-slash-menu-items/package.jsonexamples/03-ui-components/06-suggestion-menus-slash-menu-items/vite-env.d.tsexamples/03-ui-components/06-suggestion-menus-slash-menu-items/vite.config.tsexamples/03-ui-components/07-suggestion-menus-slash-menu-component/package.jsonexamples/03-ui-components/07-suggestion-menus-slash-menu-component/vite-env.d.tsexamples/03-ui-components/07-suggestion-menus-slash-menu-component/vite.config.tsexamples/03-ui-components/08-suggestion-menus-emoji-picker-columns/package.jsonexamples/03-ui-components/08-suggestion-menus-emoji-picker-columns/vite-env.d.tsexamples/03-ui-components/08-suggestion-menus-emoji-picker-columns/vite.config.tsexamples/03-ui-components/09-suggestion-menus-emoji-picker-component/package.jsonexamples/03-ui-components/09-suggestion-menus-emoji-picker-component/vite-env.d.tsexamples/03-ui-components/09-suggestion-menus-emoji-picker-component/vite.config.tsexamples/03-ui-components/10-suggestion-menus-grid-mentions/package.jsonexamples/03-ui-components/10-suggestion-menus-grid-mentions/vite-env.d.tsexamples/03-ui-components/10-suggestion-menus-grid-mentions/vite.config.tsexamples/03-ui-components/11-uppy-file-panel/package.jsonexamples/03-ui-components/11-uppy-file-panel/vite-env.d.tsexamples/03-ui-components/11-uppy-file-panel/vite.config.tsexamples/03-ui-components/12-static-formatting-toolbar/package.jsonexamples/03-ui-components/12-static-formatting-toolbar/vite-env.d.tsexamples/03-ui-components/12-static-formatting-toolbar/vite.config.tsexamples/03-ui-components/13-custom-ui/package.jsonexamples/03-ui-components/13-custom-ui/vite-env.d.tsexamples/03-ui-components/13-custom-ui/vite.config.tsexamples/03-ui-components/14-experimental-mobile-formatting-toolbar/package.jsonexamples/03-ui-components/14-experimental-mobile-formatting-toolbar/vite-env.d.tsexamples/03-ui-components/14-experimental-mobile-formatting-toolbar/vite.config.tsexamples/03-ui-components/15-advanced-tables/package.jsonexamples/03-ui-components/15-advanced-tables/vite-env.d.tsexamples/03-ui-components/15-advanced-tables/vite.config.tsexamples/03-ui-components/16-link-toolbar-buttons/package.jsonexamples/03-ui-components/16-link-toolbar-buttons/vite-env.d.tsexamples/03-ui-components/16-link-toolbar-buttons/vite.config.tsexamples/03-ui-components/17-advanced-tables-2/package.jsonexamples/03-ui-components/17-advanced-tables-2/vite-env.d.tsexamples/03-ui-components/17-advanced-tables-2/vite.config.tsexamples/03-ui-components/18-drag-n-drop/package.jsonexamples/03-ui-components/18-drag-n-drop/vite-env.d.tsexamples/03-ui-components/18-drag-n-drop/vite.config.tsexamples/03-ui-components/19-suggestion-menus-grouping-ordering/package.jsonexamples/03-ui-components/19-suggestion-menus-grouping-ordering/vite-env.d.tsexamples/03-ui-components/19-suggestion-menus-grouping-ordering/vite.config.tsexamples/03-ui-components/20-portal-elements/package.jsonexamples/03-ui-components/20-portal-elements/vite-env.d.tsexamples/03-ui-components/20-portal-elements/vite.config.tsexamples/04-theming/01-theming-dom-attributes/package.jsonexamples/04-theming/01-theming-dom-attributes/vite-env.d.tsexamples/04-theming/01-theming-dom-attributes/vite.config.tsexamples/04-theming/02-changing-font/package.jsonexamples/04-theming/02-changing-font/vite-env.d.tsexamples/04-theming/02-changing-font/vite.config.tsexamples/04-theming/03-theming-css/package.jsonexamples/04-theming/03-theming-css/vite-env.d.tsexamples/04-theming/03-theming-css/vite.config.tsexamples/04-theming/04-theming-css-variables/package.jsonexamples/04-theming/04-theming-css-variables/vite-env.d.tsexamples/04-theming/04-theming-css-variables/vite.config.tsexamples/04-theming/05-theming-css-variables-code/package.jsonexamples/04-theming/05-theming-css-variables-code/vite-env.d.tsexamples/04-theming/05-theming-css-variables-code/vite.config.tsexamples/04-theming/06-code-block/package.jsonexamples/04-theming/06-code-block/vite-env.d.tsexamples/04-theming/06-code-block/vite.config.tsexamples/04-theming/07-custom-code-block/package.jsonexamples/04-theming/07-custom-code-block/vite-env.d.tsexamples/04-theming/07-custom-code-block/vite.config.tsexamples/05-interoperability/01-converting-blocks-to-html/package.jsonexamples/05-interoperability/01-converting-blocks-to-html/vite-env.d.tsexamples/05-interoperability/01-converting-blocks-to-html/vite.config.tsexamples/05-interoperability/02-converting-blocks-from-html/package.jsonexamples/05-interoperability/02-converting-blocks-from-html/vite-env.d.tsexamples/05-interoperability/02-converting-blocks-from-html/vite.config.tsexamples/05-interoperability/03-converting-blocks-to-md/package.jsonexamples/05-interoperability/03-converting-blocks-to-md/vite-env.d.tsexamples/05-interoperability/03-converting-blocks-to-md/vite.config.tsexamples/05-interoperability/04-converting-blocks-from-md/package.jsonexamples/05-interoperability/04-converting-blocks-from-md/vite-env.d.tsexamples/05-interoperability/04-converting-blocks-from-md/vite.config.tsexamples/05-interoperability/05-converting-blocks-to-pdf/package.jsonexamples/05-interoperability/05-converting-blocks-to-pdf/vite-env.d.tsexamples/05-interoperability/05-converting-blocks-to-pdf/vite.config.tsexamples/05-interoperability/06-converting-blocks-to-docx/package.jsonexamples/05-interoperability/06-converting-blocks-to-docx/vite-env.d.tsexamples/05-interoperability/06-converting-blocks-to-docx/vite.config.tsexamples/05-interoperability/07-converting-blocks-to-odt/package.jsonexamples/05-interoperability/07-converting-blocks-to-odt/vite-env.d.tsexamples/05-interoperability/07-converting-blocks-to-odt/vite.config.tsexamples/05-interoperability/08-converting-blocks-to-react-email/package.jsonexamples/05-interoperability/08-converting-blocks-to-react-email/vite-env.d.tsexamples/05-interoperability/08-converting-blocks-to-react-email/vite.config.tsexamples/05-interoperability/09-blocks-to-html-static-render/package.jsonexamples/05-interoperability/09-blocks-to-html-static-render/vite-env.d.tsexamples/05-interoperability/09-blocks-to-html-static-render/vite.config.tsexamples/05-interoperability/10-static-html-render/package.jsonexamples/05-interoperability/10-static-html-render/vite-env.d.tsexamples/05-interoperability/10-static-html-render/vite.config.tsexamples/06-custom-schema/01-alert-block/package.jsonexamples/06-custom-schema/01-alert-block/vite-env.d.tsexamples/06-custom-schema/01-alert-block/vite.config.tsexamples/06-custom-schema/02-suggestion-menus-mentions/package.jsonexamples/06-custom-schema/02-suggestion-menus-mentions/vite-env.d.tsexamples/06-custom-schema/02-suggestion-menus-mentions/vite.config.tsexamples/06-custom-schema/03-font-style/package.jsonexamples/06-custom-schema/03-font-style/vite-env.d.tsexamples/06-custom-schema/03-font-style/vite.config.tsexamples/06-custom-schema/04-pdf-file-block/package.jsonexamples/06-custom-schema/04-pdf-file-block/vite-env.d.tsexamples/06-custom-schema/04-pdf-file-block/vite.config.tsexamples/06-custom-schema/05-alert-block-full-ux/package.jsonexamples/06-custom-schema/05-alert-block-full-ux/vite-env.d.tsexamples/06-custom-schema/05-alert-block-full-ux/vite.config.tsexamples/06-custom-schema/06-toggleable-blocks/package.jsonexamples/06-custom-schema/06-toggleable-blocks/vite-env.d.tsexamples/06-custom-schema/06-toggleable-blocks/vite.config.tsexamples/06-custom-schema/07-configuring-blocks/package.jsonexamples/06-custom-schema/07-configuring-blocks/vite-env.d.tsexamples/06-custom-schema/07-configuring-blocks/vite.config.tsexamples/06-custom-schema/08-non-editable-block/package.jsonexamples/06-custom-schema/08-non-editable-block/vite-env.d.tsexamples/06-custom-schema/08-non-editable-block/vite.config.tsexamples/06-custom-schema/draggable-inline-content/package.jsonexamples/06-custom-schema/draggable-inline-content/vite-env.d.tsexamples/06-custom-schema/draggable-inline-content/vite.config.tsexamples/06-custom-schema/react-custom-blocks/package.jsonexamples/06-custom-schema/react-custom-blocks/vite-env.d.tsexamples/06-custom-schema/react-custom-blocks/vite.config.tsexamples/06-custom-schema/react-custom-inline-content/package.jsonexamples/06-custom-schema/react-custom-inline-content/vite-env.d.tsexamples/06-custom-schema/react-custom-inline-content/vite.config.tsexamples/06-custom-schema/react-custom-styles/package.jsonexamples/06-custom-schema/react-custom-styles/vite-env.d.tsexamples/06-custom-schema/react-custom-styles/vite.config.tsexamples/07-collaboration/01-partykit/package.jsonexamples/07-collaboration/01-partykit/vite-env.d.tsexamples/07-collaboration/01-partykit/vite.config.tsexamples/07-collaboration/02-liveblocks/package.jsonexamples/07-collaboration/02-liveblocks/vite-env.d.tsexamples/07-collaboration/02-liveblocks/vite.config.tsexamples/07-collaboration/03-y-sweet/package.jsonexamples/07-collaboration/03-y-sweet/vite-env.d.tsexamples/07-collaboration/03-y-sweet/vite.config.tsexamples/07-collaboration/04-electric-sql/package.jsonexamples/07-collaboration/04-electric-sql/vite-env.d.tsexamples/07-collaboration/04-electric-sql/vite.config.tsexamples/07-collaboration/05-comments/package.jsonexamples/07-collaboration/05-comments/vite-env.d.tsexamples/07-collaboration/05-comments/vite.config.tsexamples/07-collaboration/06-comments-with-sidebar/package.jsonexamples/07-collaboration/06-comments-with-sidebar/vite-env.d.tsexamples/07-collaboration/06-comments-with-sidebar/vite.config.tsexamples/07-collaboration/07-ghost-writer/package.jsonexamples/07-collaboration/07-ghost-writer/vite-env.d.tsexamples/07-collaboration/07-ghost-writer/vite.config.tsexamples/07-collaboration/08-forking/package.jsonexamples/07-collaboration/08-forking/vite-env.d.tsexamples/07-collaboration/08-forking/vite.config.tsexamples/07-collaboration/09-comments-testing/package.jsonexamples/07-collaboration/09-comments-testing/vite-env.d.tsexamples/07-collaboration/09-comments-testing/vite.config.tsexamples/07-collaboration/10-suggestion-multi-editor/package.jsonexamples/07-collaboration/10-suggestion-multi-editor/vite-env.d.tsexamples/07-collaboration/10-suggestion-multi-editor/vite.config.tsexamples/07-collaboration/11-versioning-yjs13/package.jsonexamples/07-collaboration/11-versioning-yjs13/vite-env.d.tsexamples/07-collaboration/11-versioning-yjs13/vite.config.tsexamples/07-collaboration/12-multi-doc-versioning/package.jsonexamples/07-collaboration/12-multi-doc-versioning/vite-env.d.tsexamples/07-collaboration/12-multi-doc-versioning/vite.config.tsexamples/07-collaboration/13-versioning-yjs14/package.jsonexamples/07-collaboration/13-versioning-yjs14/vite-env.d.tsexamples/07-collaboration/13-versioning-yjs14/vite.config.tsexamples/07-collaboration/14-suggestion-gallery/package.jsonexamples/07-collaboration/14-suggestion-gallery/vite-env.d.tsexamples/07-collaboration/14-suggestion-gallery/vite.config.tsexamples/08-extensions/01-tiptap-arrow-conversion/package.jsonexamples/08-extensions/01-tiptap-arrow-conversion/vite-env.d.tsexamples/08-extensions/01-tiptap-arrow-conversion/vite.config.tsexamples/08-extensions/02-versioning/package.jsonexamples/08-extensions/02-versioning/vite-env.d.tsexamples/08-extensions/02-versioning/vite.config.tsexamples/09-ai/01-minimal/package.jsonexamples/09-ai/01-minimal/vite-env.d.tsexamples/09-ai/01-minimal/vite.config.tsexamples/09-ai/02-playground/package.jsonexamples/09-ai/02-playground/vite-env.d.tsexamples/09-ai/02-playground/vite.config.tsexamples/09-ai/03-custom-ai-menu-items/package.jsonexamples/09-ai/03-custom-ai-menu-items/vite-env.d.tsexamples/09-ai/03-custom-ai-menu-items/vite.config.tsexamples/09-ai/04-with-collaboration/package.jsonexamples/09-ai/04-with-collaboration/vite-env.d.tsexamples/09-ai/04-with-collaboration/vite.config.tsexamples/09-ai/05-manual-execution/package.jsonexamples/09-ai/05-manual-execution/vite-env.d.tsexamples/09-ai/05-manual-execution/vite.config.tsexamples/09-ai/06-client-side-transport/package.jsonexamples/09-ai/06-client-side-transport/vite-env.d.tsexamples/09-ai/06-client-side-transport/vite.config.tsexamples/09-ai/07-server-persistence/package.jsonexamples/09-ai/07-server-persistence/vite-env.d.tsexamples/09-ai/07-server-persistence/vite.config.tsexamples/vanilla-js/react-vanilla-custom-blocks/package.jsonexamples/vanilla-js/react-vanilla-custom-blocks/vite-env.d.tsexamples/vanilla-js/react-vanilla-custom-blocks/vite.config.tsexamples/vanilla-js/react-vanilla-custom-inline-content/package.jsonexamples/vanilla-js/react-vanilla-custom-inline-content/vite-env.d.tsexamples/vanilla-js/react-vanilla-custom-inline-content/vite.config.tsexamples/vanilla-js/react-vanilla-custom-styles/package.jsonexamples/vanilla-js/react-vanilla-custom-styles/vite-env.d.tsexamples/vanilla-js/react-vanilla-custom-styles/vite.config.tsexamples/vanilla-js/vanilla-custom-side-menu/package.jsonexamples/vanilla-js/vanilla-custom-side-menu/vite-env.d.tsexamples/vanilla-js/vanilla-custom-side-menu/vite.config.tspackages/dev-scripts/examples/template-react/package.json.template.tsxpackages/dev-scripts/examples/template-react/vite-env.d.ts.template.tsxpackages/dev-scripts/examples/template-react/vite.config.ts.template.tsxpnpm-workspace.yaml
| "preview": "vp preview" | ||
| "start": "vite", | ||
| "dev": "vite", | ||
| "build:prod": "tsc && vite build", |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win
Remove direct tsc usage from the standalone build scripts.
The four generated package manifests use tsc for type-checking. The repository guideline requires vp run lint and prohibits direct tsc usage.
examples/01-basic/01-minimal/package.json#L10-L10: change the script tovite build.examples/01-basic/02-block-objects/package.json#L10-L10: change the script tovite build.examples/04-theming/03-theming-css/package.json#L10-L10: change the script tovite build.examples/04-theming/04-theming-css-variables/package.json#L10-L10: change the script tovite build.
As per coding guidelines, use vp run lint for linting and type-checking; do not use tsc or prettier.
📍 Affects 4 files
examples/01-basic/01-minimal/package.json#L10-L10(this comment)examples/01-basic/02-block-objects/package.json#L10-L10examples/04-theming/03-theming-css/package.json#L10-L10examples/04-theming/04-theming-css-variables/package.json#L10-L10
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@examples/01-basic/01-minimal/package.json` at line 10, Replace the build:prod
script with vite build in examples/01-basic/01-minimal/package.json (line 10),
examples/01-basic/02-block-objects/package.json (line 10),
examples/04-theming/03-theming-css/package.json (line 10), and
examples/04-theming/04-theming-css-variables/package.json (line 10), removing
direct tsc usage from all four manifests. Use vp run lint for linting and
type-checking instead of tsc or prettier.
Source: Coding guidelines
| "preview": "vp preview" | ||
| "start": "vite", | ||
| "dev": "vite", | ||
| "build:prod": "tsc && vite build", |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -eu
printf '%s\n' '--- target package scripts ---'
for f in \
examples/01-basic/03-multi-column/package.json \
examples/04-theming/05-theming-css-variables-code/package.json \
examples/04-theming/06-code-block/package.json \
examples/04-theming/07-custom-code-block/package.json
do
printf '\n### %s\n' "$f"
cat -n "$f"
done
printf '%s\n' '--- repository command and migration context ---'
printf '\n### package-manager files\n'
git ls-files | rg '(^|/)(package.json|pnpm-lock.yaml|pnpm-workspace.yaml|vp|stackblitz|README|CONTRIBUTING|AGENTS\.md)$' || true
printf '\n### direct tsc/build:prod occurrences\n'
rg -n --glob 'package.json' '"build:prod"|(^|[^[:alnum:]_])tsc([^[:alnum:]_]|$)|vp run lint|pnpm' . || true
printf '\n### root package scripts/configuration\n'
if [ -f package.json ]; then cat -n package.json; fi
if [ -f pnpm-workspace.yaml ]; then cat -n pnpm-workspace.yaml; fiRepository: TypeCellOS/BlockNote
Length of output: 2114
🌐 Web query:
TypeCellOS/BlockNote examples/01-basic/03-multi-column/package.json build:prod tsc vp run lint
💡 Result:
The command build:prod tsc vp run lint appears to be a reference to build and quality-assurance orchestration within the TypeCellOS/BlockNote monorepo. In the context of the BlockNote project: 1. build:prod: This is a script typically used to trigger a production build of the project [1][2]. 2. tsc: Historically, this was used for TypeScript type declaration emitting [3][4]. However, recent updates to the repository have migrated type declaration processes from tsc to tsgo to improve performance [3][4]. 3. vp: This refers to the build orchestration and task execution system (often utilizing Nx) used within the monorepo [3][1][2]. Commands like vp run lint or vp run build are used to execute specific tasks across the monorepo's packages, supporting parallel execution and distributed caching [1][2]. 4. run lint: This invokes the linting process (using tools like ESLint and oxlint) to enforce code quality across the codebase [3][1][2]. The specific example mentioned, examples/01-basic/03-multi-column, is part of the BlockNote documentation and playground examples [5][6][7]. It demonstrates the usage of multi-column blocks, which are implemented via the @blocknote/xl-multi-column package [6][7]. As of August 2026, the build pipeline for BlockNote is highly optimized, utilizing Nx for task orchestration and having recently transitioned to tsgo for faster type checking [3][1][4].
Citations:
- 1: https://deepwiki.com/TypeCellOS/BlockNote/11.2-build-pipeline
- 2: https://deepwiki.com/TypeCellOS/BlockNote/11.1-monorepo-structure
- 3: feat: migrate to tsgo, fix lint warnings, and fix vp build caching #2859
- 4: 95f0b93
- 5: https://stackblitz.com/github/TypeCellOS/BlockNote/tree/main/examples/01-basic/03-multi-column
- 6: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/playground/src/examples.gen.tsx
- 7: https://deepwiki.com/TypeCellOS/BlockNote/10.3-playground-application
🌐 Web query:
TypeCellOS/BlockNote examples/04-theming/05-theming-css-variables-code/package.json
💡 Result:
The package.json file for the BlockNote example located at examples/04-theming/05-theming-css-variables-code is part of the official TypeCellOS/BlockNote repository [1][2]. This example demonstrates how to override BlockNote's default theme CSS variables [3][4]. As of the current project structure, this directory contains a standard package.json file configured for a React-based project, which has been updated to use the Vite build tool [5][6]. The file defines the necessary dependencies and scripts required to run the example, typically including react, react-dom, and the @blocknote/react and @blocknote/core packages, along with build and development scripts like dev, build, and preview [5][7]. Because the repository is managed using a monorepo structure (utilizing tools like pnpm and Nx), the package.json files in example directories are generally lightweight and rely on the workspace's root configuration for shared dependencies and build settings [8]. You can view the exact contents of this file by navigating to the official TypeCellOS/BlockNote repository on GitHub [2].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote
- 2: https://stackblitz.com/github/TypeCellOS/BlockNote/tree/main/examples/04-theming/05-theming-css-variables-code
- 3: https://github.com/TypeCellOS/BlockNote/tree/main/examples/04-theming/04-theming-css-variables
- 4: https://deepwiki.com/TypeCellOS/BlockNote/3.2-block-styling
- 5: 767a82f
- 6: feat: migrate to Vite+ #2745
- 7: bb6ead5
- 8: 7df528c
🏁 Script executed:
#!/bin/bash
set -eu
base='https://raw.githubusercontent.com/TypeCellOS/BlockNote/main'
files=(
'examples/01-basic/03-multi-column/package.json'
'examples/04-theming/05-theming-css-variables-code/package.json'
'examples/04-theming/06-code-block/package.json'
'examples/04-theming/07-custom-code-block/package.json'
'package.json'
'pnpm-workspace.yaml'
)
for path in "${files[@]}"; do
printf '\n### %s\n' "$path"
curl -fsSL "$base/$path" | nl -ba
done
printf '\n### matching package scripts in the current public tree\n'
curl -fsSL 'https://api.github.com/repos/TypeCellOS/BlockNote/git/trees/main?recursive=1' |
jq -r '.tree[] | select(.path | endswith("package.json")) | .path' |
while IFS= read -r path; do
content=$(curl -fsSL "$base/$path" 2>/dev/null || true)
if printf '%s' "$content" | grep -Eq '"build:prod"|(^|[^[:alnum:]_])tsc([^[:alnum:]_]|$)|vp run lint'; then
printf '%s\n' "$path"
printf '%s\n' "$content" | jq -r '.scripts // {} | to_entries[] | "\(.key)=\(.value)"' 2>/dev/null || true
fi
doneRepository: TypeCellOS/BlockNote
Length of output: 2114
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "examples/01-basic/03-multi-column/package.json" "\"build:prod\""
💡 Result:
In the BlockNote project repository, the build:prod script in various package.json files—including examples/01-basic/03-multi-column/package.json—was removed as part of a migration to Vite+ [1]. Previously, these files contained build scripts (such as build:prod) to manage project builds. However, following the migration to the Vite+ build system, these scripts were moved to tasks defined within the corresponding vite.config.ts files [1]. This change was implemented to improve cache management and avoid overly broad input tracking [1]. If you are looking for how to build these projects in the current repository structure, you should check the tasks defined in the vite.config.ts file for the specific package or example, or use the centralized build commands provided by the project's updated tooling [1][2].
Citations:
- 1: feat: migrate to Vite+ #2745
- 2: https://github.com/TypeCellOS/BlockNote/blob/main/packages/shadcn/vite.config.ts
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "examples/04-theming/06-code-block/package.json" "\"build:prod\""
💡 Result:
The file examples/04-theming/06-code-block/package.json is part of the BlockNote repository [1][2]. In the context of this project, build scripts like "build:prod" are typically defined within package.json files to facilitate the compilation of examples or packages using tools like Vite [3][4]. While the specific contents of "build:prod" can change as the project evolves [2][5], it generally serves as a production-optimized build command. In the BlockNote monorepo, which uses pnpm and Nx [2][6], these scripts often leverage vite build [7][4] to bundle the TypeScript/React code for production deployment. You can view the current definition of this script by navigating directly to the file in the TypeCellOS/BlockNote repository [1].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/tree/main/examples/04-theming/06-code-block
- 2: 7df528c
- 3: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/packages/react/vite.config.ts
- 4: https://github.com/TypeCellOS/BlockNote/blob/main/examples/07-collaboration/09-comments-testing/vite.config.ts
- 5: 40ddec4
- 6: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/.github/workflows/build.yml
- 7: Vite Rollup Production build tree-shaking & Large Blocknote bundles #1870
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "vp run lint" "StackBlitz"
💡 Result:
The command vp run lint is not a standard tool for StackBlitz, but rather a specific command used in projects utilizing the Vite+ (or Vite Task) build and task runner system [1][2]. In the context of the BlockNote repository and similar projects, vp is a task runner that integrates with Vite [1]. The command vp run lint triggers a configured linting task—often utilizing oxlint, which is a high-performance, Rust-based linter [1]. When you encounter or use this command: 1. Task Runner: The vp command is part of a custom workspace setup (often involving the voidzero-dev/setup-vp action in CI/CD pipelines) [3][1]. 2. Configuration: The tasks themselves, including lint, are defined within the project's configuration (usually vite.config.ts or associated task definitions) rather than standard package.json scripts [1]. 3. StackBlitz: If you are seeing this in a StackBlitz environment, it is because that specific project is configured to use the Vite+ task system [4]. If the command fails in your specific StackBlitz instance, it likely means the environment is not correctly configured to recognize the vp binary or the task graph is missing dependencies (e.g., needing a build step before linting, as is often the case with type-aware linting) [5][6]. To troubleshoot or run it correctly, ensure you have the necessary project dependencies installed and that the environment supports the Vite+ task runner [1][7].
Citations:
- 1: feat: migrate to Vite+ #2745
- 2: 767a82f
- 3: https://github.com/TypeCellOS/BlockNote/blob/ade62f2b360a35629a376aa2d3de71cb06719872/.github/workflows/fresh-install-tests.yml
- 4: fix: ShadCN example Tailwind setup #2042
- 5: 729a3d2
- 6: 41df112
- 7: b902dbb
🌐 Web query:
GitHub TypeCellOS BlockNote pull 2745 examples 01-basic 03-multi-column package.json build:prod
💡 Result:
Pull request #2745 in the TypeCellOS/BlockNote repository marks the migration of the project's build system to Vite [1]. Regarding the specific items mentioned: 01-basic and 03-multi-column: These refer to directory paths within the BlockNote repository's example system [2]. Specifically, 01-basic is a category of examples focused on core features and setup, and 03-multi-column is a project within that category demonstrating multi-column block functionality (often utilizing the @blocknote/xl-multi-column package) [3][4][2]. package.json build:prod: Following the migration to Vite, the build:prod script in package.json is typically configured to execute the Vite production build command, often paired with TypeScript compilation (e.g., "tsc && vite build" or similar variations) to prepare the application for a production environment [5][6]. This is a standard pattern in modern React and TypeScript projects to ensure assets are optimized, minified, and compiled correctly [6].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/blob/main/CHANGELOG.md
- 2: https://deepwiki.com/TypeCellOS/BlockNote/10.1-example-system
- 3: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/playground/src/examples.gen.tsx
- 4: https://deepwiki.com/TypeCellOS/BlockNote/10.3-playground-application
- 5: https://stackblitz.com/edit/github-thjchykw?file=package.json
- 6: https://www.mintlify.com/EdgarJr30/proyecto-de-grado-cms/deployment/production-build
🌐 Web query:
GitHub TypeCellOS BlockNote pull 2745 examples 04-theming 05-theming-css-variables-code 06-code-block 07-custom-code-block package.json
💡 Result:
In the TypeCellOS BlockNote repository, pull request #2745 is a significant maintenance update that migrated the project to Vite [1][2]. The path components you mentioned refer to official example projects and documentation sections within the BlockNote ecosystem, specifically related to theming and code block customization: 04-theming: This directory contains examples for styling and customizing the BlockNote editor [3]. 05-theming-css-variables-code: This refers to an example demonstrating how to define and apply custom themes using code (i.e., passing a theme object to the BlockNoteView component) [4]. 06-code-block: This is the standard example for enabling and configuring code block syntax highlighting in the editor [5]. 07-custom-code-block: This example demonstrates how to configure advanced code block features, such as custom syntax highlighting themes and specific language support using the Shiki highlighter [6][3]. For any of these examples, the associated package.json file (located in the root of the respective example directory in the GitHub repository) manages the necessary dependencies (such as @blocknote/core, @blocknote/react, and @blocknote/mantine) required to run that specific feature demonstration. To implement these features in your own project, ensure you have the required BlockNote packages installed and that your schema is extended with the appropriate block specifications [6][5][7].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/blob/main/CHANGELOG.md
- 2: https://github.com/TypeCellOS/BlockNote/releases
- 3: https://github.com/TypeCellOS/BlockNote/tree/main/examples/04-theming/07-custom-code-block
- 4: https://www.blocknotejs.org/examples/theming/theming-css-variables-code
- 5: https://www.blocknotejs.org/examples/theming/code-block
- 6: https://www.blocknotejs.org/examples/theming/custom-code-block
- 7: https://www.blocknotejs.org/docs/features/blocks/code-blocks
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "examples/04-theming/07-custom-code-block" "build:prod"
💡 Result:
The path examples/04-theming/07-custom-code-block refers to a specific example directory within the BlockNote repository (TypeCellOS/BlockNote) [1][2]. This example demonstrates how to implement and theme a custom code block in the BlockNote editor, specifically using the @blocknote/code-block package and Shiki for syntax highlighting [1][2]. Regarding the build:prod suffix mentioned in your query, it is not a standard part of the directory path itself, but rather a common command used to build projects in production mode (e.g., npm run build:prod or pnpm build:prod). In the context of the BlockNote project, this example covers: 1. Extending the editor's default schema to include a custom code block [1]. 2. Configuring code block highlighting themes and languages [1]. 3. Utilizing a Shiki highlighter bundle (often generated via a CLI tool) to manage syntax highlighting [1][2]. If you are attempting to build this specific example, ensure you are in the root or appropriate workspace directory of the BlockNote repository and use the package manager's build command as defined in the package.json file [2][3].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/tree/main/examples/04-theming/07-custom-code-block
- 2: feat: upgrade shiki to v4 and prosemirror-highlight to v0.15.1 #2625
- 3: 40ddec4
Replace direct tsc invocations in all four build:prod scripts. Use vp run lint for type-checking before vite build. If StackBlitz does not provide vp, define and test an explicit exception.
📍 Affects 4 files
examples/01-basic/03-multi-column/package.json#L10-L10(this comment)examples/04-theming/05-theming-css-variables-code/package.json#L10-L10examples/04-theming/06-code-block/package.json#L10-L10examples/04-theming/07-custom-code-block/package.json#L10-L10
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@examples/01-basic/03-multi-column/package.json` at line 10, Replace the
direct tsc invocation in the build:prod script of
examples/01-basic/03-multi-column/package.json,
examples/04-theming/05-theming-css-variables-code/package.json,
examples/04-theming/06-code-block/package.json, and
examples/04-theming/07-custom-code-block/package.json with vp run lint before
vite build. If StackBlitz lacks vp, define and test an explicit exception.
Source: Coding guidelines
| "preview": "vp preview" | ||
| "start": "vite", | ||
| "dev": "vite", | ||
| "build:prod": "tsc && vite build", |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win
Use the prescribed type-check command consistently.
The four standalone package scripts invoke tsc directly. Replace it with vp run lint, or document an explicit exception for standalone examples.
examples/01-basic/08-ariakit/package.json#L10-L10: Updatebuild:prod.examples/05-interoperability/05-converting-blocks-to-pdf/package.json#L10-L10: Updatebuild:prod.examples/05-interoperability/06-converting-blocks-to-docx/package.json#L10-L10: Updatebuild:prod.examples/05-interoperability/07-converting-blocks-to-odt/package.json#L10-L10: Updatebuild:prod.
As per coding guidelines, **/* requires vp run lint for linting and type-checking and forbids tsc or prettier.
📍 Affects 4 files
examples/01-basic/08-ariakit/package.json#L10-L10(this comment)examples/05-interoperability/05-converting-blocks-to-pdf/package.json#L10-L10examples/05-interoperability/06-converting-blocks-to-docx/package.json#L10-L10examples/05-interoperability/07-converting-blocks-to-odt/package.json#L10-L10
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@examples/01-basic/08-ariakit/package.json` at line 10, Replace the direct tsc
invocation in the build:prod script with vp run lint in
examples/01-basic/08-ariakit/package.json:10-10,
examples/05-interoperability/05-converting-blocks-to-pdf/package.json:10-10,
examples/05-interoperability/06-converting-blocks-to-docx/package.json:10-10,
and examples/05-interoperability/07-converting-blocks-to-odt/package.json:10-10,
preserving the existing Vite build step.
Source: Coding guidelines
| "preview": "vp preview" | ||
| "start": "vite", | ||
| "dev": "vite", | ||
| "build:prod": "tsc && vite build", |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -eu
for f in \
examples/01-basic/14-editor-scrollable/package.json \
examples/01-basic/15-shadowdom/package.json \
examples/06-custom-schema/05-alert-block-full-ux/package.json \
examples/06-custom-schema/06-toggleable-blocks/package.json
do
echo "=== $f ==="
cat -n "$f"
done
echo "=== repository command configuration ==="
git ls-files | rg '(^|/)(package\.json|vp\.toml|vp\.json|pnpm-workspace\.yaml|pnpm-lock\.yaml|CONTRIBUTING|README)(|\.md)$' | head -200
echo "=== relevant command declarations ==="
rg -n --glob 'package.json' --glob '!node_modules/**' '"(build:prod|lint|typecheck|check|format)"|(^|[^[:alnum:]_])tsc([^[:alnum:]_]|$)|vp run' .Repository: TypeCellOS/BlockNote
Length of output: 2114
🌐 Web query:
TypeCellOS BlockNote examples/01-basic/14-editor-scrollable/package.json build:prod tsc
💡 Result:
The command build:prod tsc found in the package.json file of the examples/01-basic/14-editor-scrollable directory within the TypeCellOS/BlockNote repository is a build script used to compile the example application [1][2]. In the context of this repository, the build:prod script typically invokes the TypeScript compiler (tsc) to perform type-checking or production-ready builds of the specific example code [1][3]. The BlockNote library is a block-based, extensible React rich text editor built on Prosemirror and Tiptap [4][5]. The editor-scrollable example specifically demonstrates how to configure the component to handle scrolling within a container, often by manipulating CSS classes such as.bn-editor to set the height [6][7]. The codebase has undergone migrations to modern build tools like Vite and tsgo to manage type declarations and build processes, ensuring that examples remain compatible with the project's build infrastructure [1][3][8].
Citations:
- 1: feat: migrate to Vite+ #2745
- 2: bb6ead5
- 3: feat: migrate to tsgo, fix lint warnings, and fix vp build caching #2859
- 4: https://github.com/TypeCellOS/BlockNote
- 5: https://www.blocknotejs.org/
- 6: https://blocknote-main.vercel.app/basic/editor-scrollable
- 7: https://stackoverflow.com/questions/79638822/how-to-make-blocknoteview-fill-the-height-of-its-parent-container
- 8: 95f0b93
🌐 Web query:
TypeCellOS BlockNote coding guidelines "Use vp run lint" tsc package.json
💡 Result:
In the TypeCellOS BlockNote repository, the development workflow has been migrated to Vite+ (vp) [1]. Consequently, traditional scripts like tsc have been largely replaced or integrated into the vp task runner [2][1]. Key details regarding your query: 1. Linting and Type Checking: The repository now uses type-aware oxlint for linting, which is faster than traditional ESLint [2][1]. Type declarations are handled by tsgo rather than tsc across all packages [2]. 2. Executing Tasks: You can run project tasks using the vp command-line tool [3]. - To run linting: Use the command vp lint [4][5]. - To run builds (which includes type declaration generation via tsgo): Use the command vp run build (or vp run -r build to run across all packages) [5]. 3. package.json: While you may still see scripts in package.json, the preferred method is to use vp run for task-level caching and optimized dependency ordering [3]. Refer to the project's root vite.config.ts for the definitive list of tasks and their configurations [3][6]. 4. Contributing Guidelines: For the most up-to-date guidance, please consult the CONTRIBUTING.md file in the root of the BlockNote repository, which contains the latest instructions for local development [7].
Citations:
- 1: feat: migrate to Vite+ #2745
- 2: feat: migrate to tsgo, fix lint warnings, and fix vp build caching #2859
- 3: https://viteplus.dev/guide/run
- 4: https://github.com/code/app-blocknote-mpl/blob/main/AGENTS.md
- 5: https://github.com/TypeCellOS/BlockNote/blob/33242468bcc08ca737b595027944106df5e35580/.github/workflows/build.yml
- 6: https://viteplus.dev/config/run
- 7: https://github.com/TypeCellOS/BlockNote
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "examples/01-basic/15-shadowdom/package.json" "build:prod"
💡 Result:
The command build:prod within the context of examples/01-basic/15-shadowdom/package.json refers to a build script used in the BlockNote project [1][2][3]. In the BlockNote repository, the folder examples/01-basic/15-shadowdom serves as an example implementation demonstrating how to use the BlockNote editor within a Shadow DOM environment [4][5][6]. The package.json file located in this directory typically contains scripts defined for managing the build and development lifecycle of that specific example, including the build:prod script, which is used to create a production-ready build of the example application [3]. The BlockNote project has undergone significant migration to modern tooling, including migrating to Vite [5][3]. Consequently, scripts like build:prod in these example packages are configured to leverage Vite's build process to bundle the application code for production deployment [5][3]. General context for this example: - Purpose: It demonstrates that BlockNote can be mounted within a Shadow DOM, a requirement for frameworks or applications that isolate their components (e.g., OpenProject) [4][7][6]. - Technical Implementation: The project ensures Shadow DOM compatibility by replacing global document references with root-aware references (such as view.root) and refining how selection states are handled to avoid issues with standard browser APIs like window.getSelection in shadowed environments [7][6].
Citations:
- 1: 40ddec4
- 2: https://github.com/TypeCellOS/BlockNote/tree/main/examples/01-basic
- 3: 767a82f
- 4: fix: shadowdom support and example #2223
- 5: feat: migrate to Vite+ #2745
- 6: fix(clipboard): use ProseMirror selection state for Shadow DOM compatibility #2677
- 7: Update: ShadowRoot support #849
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "examples/06-custom-schema/05-alert-block-full-ux/package.json" "build:prod"
💡 Result:
The command build:prod is an npm (or package manager) script defined within the package.json file of the BlockNote project's example, located at examples/06-custom-schema/05-alert-block-full-ux/package.json [1][2][3]. In the context of the BlockNote monorepo, this script is used to trigger a production-ready build of that specific example project. Historically, the project utilized npm and lerna [4], but it has transitioned to using pnpm and NX [5][4]. Consequently, while build:prod might still be referenced in specific legacy examples or documentation, modern build processes in the repository typically rely on pnpm or the vp (VoidZero) runner to handle builds across the workspace, often via commands like vp run -r build or similar [6]. If you are working within this codebase, you should check the current scripts section of the specific package.json file to confirm the exact command mapped to build:prod, as build configurations and tooling in this repository have evolved [5][4][6].
Citations:
- 1: 40ddec4
- 2: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/playground/src/examples.gen.tsx
- 3: aaa1577
- 4: 7df528c
- 5: chore: use pnpm instead of npm #1567
- 6: https://github.com/TypeCellOS/BlockNote/blob/c7274dd5e043fccbef0f7c754de881ee47e0c8b4/.github/workflows/build.yml
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "examples/06-custom-schema/06-toggleable-blocks/package.json" "build:prod"
💡 Result:
The build:prod script associated with examples/06-custom-schema/06-toggleable-blocks/package.json in the BlockNote repository is a standard command used to initiate a production build of the example project, typically leveraging Vite [1]. In the context of the BlockNote examples directory, these package.json files are used to manage individual example configurations [2]. When running npm run build:prod within such a directory, it executes the build process defined in the scripts section of that package.json file, which generally invokes a bundler (such as Vite) to compile the React/TypeScript code into optimized assets for production [1]. The "Toggleable Custom Blocks" example itself demonstrates how to implement custom blocks with a toggle button to show or hide their children using the ToggleWrapper component from @blocknote/react [3]. While the specific content of the scripts object in that exact package.json may change with repository updates, it follows the standard pattern for projects within the BlockNote monorepo to support local development and production-ready output [4][2].
Citations:
- 1: Vite Rollup Production build tree-shaking & Large Blocknote bundles #1870
- 2: https://github.com/TypeCellOS/BlockNote/tree/main/examples
- 3: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/playground/src/examples.gen.tsx
- 4: https://github.com/TypeCellOS/BlockNote/tree/main/examples/06-custom-schema
Remove the direct tsc command from all four build:prod scripts.
Use the repository’s vp task for type-checking instead.
📍 Affects 4 files
examples/01-basic/14-editor-scrollable/package.json#L10-L10(this comment)examples/01-basic/15-shadowdom/package.json#L10-L10examples/06-custom-schema/05-alert-block-full-ux/package.json#L10-L10examples/06-custom-schema/06-toggleable-blocks/package.json#L10-L10
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@examples/01-basic/14-editor-scrollable/package.json` at line 10, Update the
build:prod scripts to remove the direct tsc command and use the repository’s vp
task for type-checking while preserving the Vite build. Apply this change in
examples/01-basic/14-editor-scrollable/package.json:10-10,
examples/01-basic/15-shadowdom/package.json:10-10,
examples/06-custom-schema/05-alert-block-full-ux/package.json:10-10, and
examples/06-custom-schema/06-toggleable-blocks/package.json:10-10.
Source: Coding guidelines
| "preview": "vp preview" | ||
| "start": "vite", | ||
| "dev": "vite", | ||
| "build:prod": "tsc && vite build", |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win
Remove direct tsc usage from the generated example build scripts. The repository guidelines require vp run lint for type-checking and prohibit direct tsc usage.
examples/01-basic/testing/package.json#L10-L10: replace or removetsc && vite build.examples/06-custom-schema/draggable-inline-content/package.json#L10-L10: replace or removetsc && vite build.examples/06-custom-schema/react-custom-blocks/package.json#L10-L10: replace or removetsc && vite build.examples/06-custom-schema/react-custom-inline-content/package.json#L10-L10: replace or removetsc && vite build.
As per coding guidelines, use vp run lint for linting and type-checking and do not use tsc or prettier.
📍 Affects 4 files
examples/01-basic/testing/package.json#L10-L10(this comment)examples/06-custom-schema/draggable-inline-content/package.json#L10-L10examples/06-custom-schema/react-custom-blocks/package.json#L10-L10examples/06-custom-schema/react-custom-inline-content/package.json#L10-L10
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@examples/01-basic/testing/package.json` at line 10, Remove direct tsc usage
from the build:prod scripts in examples/01-basic/testing/package.json:10,
examples/06-custom-schema/draggable-inline-content/package.json:10,
examples/06-custom-schema/react-custom-blocks/package.json:10, and
examples/06-custom-schema/react-custom-inline-content/package.json:10. Replace
or remove the tsc invocation while preserving the Vite production build, and use
vp run lint for type-checking and linting in accordance with repository
guidelines.
Source: Coding guidelines
| "preview": "vp preview" | ||
| "start": "vite", | ||
| "dev": "vite", | ||
| "build:prod": "tsc && vite build", |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟠 Major | 🏗️ Heavy lift
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -eu
printf '%s\n' '--- affected package scripts ---'
for f in \
examples/03-ui-components/07-suggestion-menus-slash-menu-component/package.json \
examples/03-ui-components/08-suggestion-menus-emoji-picker-columns/package.json \
examples/07-collaboration/14-suggestion-gallery/package.json \
examples/08-extensions/01-tiptap-arrow-conversion/package.json
do
printf '\n%s\n' "$f"
sed -n '1,24p' "$f"
done
printf '%s\n' '--- repository policy and generation references ---'
rg -n --hidden -g '!node_modules' -g '!dist' -g '!build' \
'build:prod|tsc && vite build|vp run lint|generated|generate.*example|example.*generate' \
. | head -n 300
printf '%s\n' '--- candidate generator files ---'
git ls-files | rg '(^|/)(package\.json|.*(generate|template|example).*)$' | head -n 300Repository: TypeCellOS/BlockNote
Length of output: 2114
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "tsc && vite build" "build:prod"
💡 Result:
The command tsc && vite build is a shell script sequence commonly found in package.json build scripts for TypeScript-based projects using Vite [1]. The sequence operates as follows: 1. tsc: This runs the TypeScript compiler [1]. In this context, it is typically used to type-check the project and/or emit declaration files (.d.ts) before the bundling process begins [2][3]. 2. &&: This is a logical AND operator in shell environments. It ensures that the second command (vite build) only executes if the first command (tsc) completes successfully without errors [1]. 3. vite build: This invokes Vite to bundle the application for production [1]. Regarding the specific segment build:prod mentioned in your query: - If you see a command formatted like tsc && vite build build:prod, it is likely a misinterpretation of a script command. Vite's build command does not natively accept a build:prod argument [1][4]. - In many projects, build:prod is instead the name of an npm script itself (e.g., "build:prod": "tsc && vite build") [1]. It is possible you are looking at a package.json where someone has combined these, or encountered a typo in a command line instruction. If you encounter this pattern in a monorepo (such as the BlockNote project where these commands are frequent), it is used to ensure that code is type-safe and that type definitions are generated before Vite produces the final production assets [2][3][1].
Citations:
- 1: blocknote TextSelection endpoint not pointing into a node with inline content (doc) #1606
- 2: 95f0b93
- 3: feat: migrate to tsgo, fix lint warnings, and fix vp build caching #2859
- 4: https://github.com/TypeCellOS/BlockNote/blob/main/packages/shadcn/vite.config.ts
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "build:prod" "vp run lint"
💡 Result:
The command vp run lint is a task execution command associated with Vite+ (vp), a tooling system used in the BlockNote monorepo to manage build tasks, caching, and development workflows [1][2]. In this ecosystem: 1. vp (Vite+) is a command-line tool that replaces or augments traditional task runners like Nx or pnpm for managing scripts, such as building, testing, and linting, with a focus on fast, cached execution [2]. 2. The command structure vp run lint executes the linting task configured within the Vite+ system [2]. 3. The phrase build:prod likely refers to a specific build configuration or environment variable (production build) that is often defined or invoked alongside these tasks to ensure that artifacts—such as compiled type declarations or distribution files—are generated before running tasks like type-aware linting [3][1]. For example, it is a common practice in this environment to run a build step before linting, specifically to ensure that dist/ files are available for type-aware linters (like oxlint) to correctly resolve cross-package imports [3]. The Vite+ system is designed to handle these task dependencies efficiently, often achieving significant speed improvements over traditional tools like ESLint and Prettier by utilizing Rust-based alternatives [2].
Citations:
- 1: feat: migrate to tsgo, fix lint warnings, and fix vp build caching #2859
- 2: feat: migrate to Vite+ #2745
- 3: 729a3d2
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "suggestion-menus-slash-menu-component" package.json
💡 Result:
The "suggestion-menus-slash-menu-component" refers to a specific example project within the BlockNote repository, a React-based rich text editor [1][2]. This is not a standalone npm package, but rather a directory located within the examples folder of the BlockNote source code, typically found at: examples/03-ui-components/07-suggestion-menus-slash-menu-component/ As an example project, its package.json file defines dependencies required for that specific demonstration, such as BlockNote core packages, React, and build tools like Vite [3][4][5]. Because it is part of the main repository's example suite, its dependencies are frequently updated alongside the rest of the project [6][7][8]. You can access the source code, including the package.json, directly from the official BlockNote GitHub repository [1].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/tree/main/examples/03-ui-components/07-suggestion-menus-slash-menu-component
- 2: https://github.com/TypeCellOS/BlockNote
- 3: feat: migrate to Vite+ #2745
- 4: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/playground/src/examples.gen.tsx
- 5: 767a82f
- 6: bd802f6
- 7: 40ddec4
- 8: ce995ee
🏁 Script executed:
#!/bin/bash
set -eu
base='https://raw.githubusercontent.com/TypeCellOS/BlockNote/main'
files=(
'examples/03-ui-components/07-suggestion-menus-slash-menu-component/package.json'
'examples/03-ui-components/08-suggestion-menus-emoji-picker-columns/package.json'
'examples/07-collaboration/14-suggestion-gallery/package.json'
'examples/08-extensions/01-tiptap-arrow-conversion/package.json'
'package.json'
'vite.config.ts'
'vp.json'
)
for f in "${files[@]}"; do
printf '\n--- %s ---\n' "$f"
curl -fsSL "$base/$f" | sed -n '1,80p' || printf '%s\n' '[not found]'
done
printf '\n--- repository tree candidates ---\n'
curl -fsSL 'https://api.github.com/repos/TypeCellOS/BlockNote/git/trees/main?recursive=1' |
jq -r '.tree[]?.path' |
rg -i '(^|/)(package\.json|.*(generate|template|example).*)$' |
rg -i '(script|example|generate|template|config|vp|vite)' |
head -n 300Repository: TypeCellOS/BlockNote
Length of output: 2114
🌐 Web query:
https://raw.githubusercontent.com/TypeCellOS/BlockNote/main/examples/03-ui-components/07-suggestion-menus-slash-menu-component/package.json
💡 Result:
The file you referenced is a package.json file from the BlockNote repository [1][2], an open-source, block-based rich text editor for React [3][4]. Specifically, this file belongs to an example project that demonstrates how to replace the default "Slash Menu" (the context menu that appears when a user types '/') with a custom UI component [5][6]. BlockNote is built on top of ProseMirror and Tiptap [1][4]. The repository is structured as a monorepo [4], and this example is located in the UI components section, illustrating how developers can leverage the SuggestionMenuController to implement their own menu logic and styling [5][6]. Key details about this component: - Purpose: It shows how to disable the default Slash Menu by passing slashMenu={false} to the BlockNoteView component and then using the SuggestionMenuController to render a custom React component for the menu [5][6]. - Functionality: The SuggestionMenuController manages the position, visibility, and filtering of items, while the custom component provided to the suggestionMenuComponent prop handles the actual visual rendering of the menu items [6]. - Context: This is one of many examples in the BlockNote documentation designed to help developers create highly customized document-editing experiences without needing to build the underlying text editor logic from scratch [3][6].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote
- 2: https://github.com/TypeCellOS/blocknote
- 3: https://blocknotejs.org
- 4: https://deepwiki.com/TypeCellOS/BlockNote
- 5: https://www.blocknotejs.org/examples/ui-components/suggestion-menus-slash-menu-component
- 6: https://www.blocknotejs.org/docs/react/components/suggestion-menus
🌐 Web query:
https://raw.githubusercontent.com/TypeCellOS/BlockNote/main/examples/03-ui-components/08-suggestion-menus-emoji-picker-columns/package.json
💡 Result:
The URL you provided points to the package.json file for a specific example project within the BlockNote repository, titled "Suggestion Menus - Emoji Picker Columns" [1]. BlockNote is an open-source, block-based rich text editor for React [2][3][4]. It is built on top of ProseMirror and Tiptap [4][5], designed to provide a modern, Notion-like editing experience with minimal setup [3][4]. The example corresponding to that package.json demonstrates how to customize the grid layout of the emoji picker suggestion menu [6][1]. Specifically, it shows how to use the GridSuggestionMenuController to override the default column count—in this case, setting it to 5 columns instead of the default 10—when the user triggers the menu with a specific character (e.g., ":") [6]. For more information, you can visit the official BlockNote documentation for suggestion menus [7] or the specific example page demonstrating the emoji picker column configuration [6].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/tree/main/examples/03-ui-components/08-suggestion-menus-emoji-picker-columns
- 2: https://www.blocknotejs.org/
- 3: https://www.blocknotejs.org/docs
- 4: https://github.com/TypeCellOS/BlockNote
- 5: https://github.com/typecellos/blocknote
- 6: https://www.blocknotejs.org/examples/ui-components/suggestion-menus-emoji-picker-columns
- 7: https://www.blocknotejs.org/docs/react/components/suggestion-menus
🌐 Web query:
https://raw.githubusercontent.com/TypeCellOS/BlockNote/main/examples/07-collaboration/14-suggestion-gallery/package.json
💡 Result:
The file located at the specified URL is a package.json file for a technical example within the BlockNote repository [1]. BlockNote is an open-source, block-based React rich text editor designed for developers to integrate modern, Notion-like editing capabilities into their web applications [2][3][4]. The specific example, 14-suggestion-gallery under the 07-collaboration category, is part of BlockNote's automated example system [1]. This system organizes, configures, and generates package.json files for various demonstrations [1]. Examples in the 07-collaboration category typically highlight BlockNote's support for real-time collaborative editing using Y.js (Yjs) CRDT (Conflict-free Replicated Data Type) integration [5][1]. Suggestion menus in BlockNote are UI components that allow users to trigger context-aware menus (such as slash commands or @-mentions) by typing specific characters [6][7]. In summary, this package.json file serves as the configuration for a demo that showcases how to implement and customize suggestion menus within a collaborative editing environment using the BlockNote framework [5][6][1].
Citations:
- 1: https://deepwiki.com/TypeCellOS/BlockNote/10.1-example-system
- 2: https://www.blocknotejs.org/
- 3: https://www.blocknotejs.org/docs
- 4: https://github.com/TypeCellOS/BlockNote
- 5: https://deepwiki.com/TypeCellOS/BlockNote/8-collaboration
- 6: https://www.blocknotejs.org/docs/react/components/suggestion-menus
- 7: https://github.com/TypeCellOS/BlockNote/tree/main/examples/03-ui-components/10-suggestion-menus-grid-mentions
🌐 Web query:
https://raw.githubusercontent.com/TypeCellOS/BlockNote/main/examples/08-extensions/01-tiptap-arrow-conversion/package.json
💡 Result:
The file referenced in your query is an official documentation example provided by the BlockNote project to demonstrate how to integrate custom TipTap extensions into a BlockNote editor [1][2][3]. Specifically, the example demonstrates how to implement an Input Rule that automatically converts the character sequence "->" into the Unicode arrow symbol "→" [1]. Key details about this example: - Purpose: It serves as an educational resource for users who want to add custom functionality—such as Input Rules—via the underlying TipTap engine that powers BlockNote [1][2]. - Implementation: It creates a custom TipTap Extension using Extension.create, which defines an addInputRules method to intercept text input [1]. - Integration: The extension is registered in the BlockNote editor by passing it to the _tiptapOptions.extensions array during initialization (e.g., in the useCreateBlockNote hook) [1][4]. This approach was established as the recommended way to handle such custom requirements after a feature request to add this functionality natively was declined in favor of keeping the core library focused and allowing for user-defined extensions [4][2]. You can view the live implementation in the official BlockNote documentation examples [1][5].
Citations:
- 1: https://www.blocknotejs.org/examples/extensions/tiptap-arrow-conversion
- 2: docs: added example custom tiptap extension (arrow conversion) #971
- 3: https://stackblitz.com/github/TypeCellOS/BlockNote/tree/main/examples/08-extensions/01-tiptap-arrow-conversion
- 4: Add built-in support for converting "->" to "→" #915
- 5: https://playground.blocknotejs.org/extensions/tiptap-arrow-conversion
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "tsc && vite build" examples
💡 Result:
The command "tsc && vite build" is a standard pattern used in many TypeScript-based projects to ensure that type checking is performed before the build process begins [1]. In this command: 1. tsc: Runs the TypeScript compiler. This command typically executes the type checker defined in your tsconfig.json file. If any TypeScript errors are found, the command will exit with a non-zero status, effectively stopping the process [1]. 2. &&: Is a shell operator that ensures the second command (vite build) only runs if the first command (tsc) completes successfully (i.e., with an exit code of 0). 3. vite build: Executes the Vite build process, which bundles your project files for production using your Vite configuration [1]. This sequence is commonly employed to prevent broken or type-unsafe code from being bundled into the production output [1]. Note: In some modern or highly optimized repositories (such as the BlockNote project, where this pattern has been observed), developers may migrate away from using tsc directly during the build step in favor of faster alternatives or custom build tools (like tsgo) to optimize build times and caching [2]. However, the tsc && vite build pattern remains a widely accepted and reliable method for enforcing type safety during the build pipeline [1].
Citations:
- 1: blocknote TextSelection endpoint not pointing into a node with inline content (doc) #1606
- 2: feat: migrate to tsgo, fix lint warnings, and fix vp build caching #2859
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "examples" "package.json" "build:prod" "generate"
💡 Result:
In the context of the BlockNote repository and similar JavaScript projects, build:prod and generate are common script tasks defined in a package.json file [1][2]. These are not standardized npm commands, but rather custom scripts tailored to the project's workflow. build:prod This script is typically used to create a production-ready bundle of the application or library [3][4]. It often triggers build tools like Vite, Rollup, or Webpack to compile, minify, and optimize the source code for deployment [3][5]. By appending:prod, developers often differentiate it from a standard build script (e.g., build:dev) that might include sourcemaps, lack minification, or omit certain production-specific optimizations [6][5]. generate This script is generally used to execute automation tasks that dynamically create or update files within the project [7]. In many development environments, this includes: - Generating documentation [1]. - Auto-creating boilerplate code or TypeScript interfaces [7]. - Synchronizing project structures, such as listing available examples or tests in a configuration file [7]. These scripts are executed via your package manager (e.g., npm run build:prod or npm run generate) [8][4]. Because these definitions vary by project, you should check the scripts section of your local package.json file to see the specific command being executed for your environment [1][2].
Citations:
- 1: 7df528c
- 2: chore: use pnpm instead of npm #1567
- 3: Vite Rollup Production build tree-shaking & Large Blocknote bundles #1870
- 4: https://github.com/TypeCellOS/BlockNote/blob/c7274dd5e043fccbef0f7c754de881ee47e0c8b4/.github/workflows/build.yml
- 5: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/packages/react/vite.config.ts
- 6: https://github.com/TypeCellOS/BlockNote/blob/main/examples/07-collaboration/09-comments-testing/vite.config.ts
- 7: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/playground/src/examples.gen.tsx
- 8: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/.github/workflows/build.yml
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "build:prod" "vite build" examples/package.json
💡 Result:
The command "build:prod vite build examples/package.json" is not a standard Vite CLI command. Based on the technical context of the project (BlockNote) and the provided query, this pattern appears to be a misinterpretation of how projects using "Vite+" (a custom task runner extension) handle build processes [1]. In the BlockNote project's migration to Vite+, the build scripts were moved from package.json files into "tasks" defined within vite.config.ts files [1]. You cannot pass a package.json file directly to the vite build command. Instead, you typically run: 1. Standard Vite: Execute vite build within the directory containing the vite.config.ts file. Vite automatically looks for this configuration file in the current working directory. 2. Vite+ (if applicable): Use the task runner command, such as vp build, which executes the tasks defined within your configuration [2][1]. If you are attempting to build an example, navigate to that specific directory and run the standard build command defined in that package's configuration [1]. If the project uses Vite+, checking the run.tasks.build configuration in the vite.config.ts file of that specific package will reveal the exact build logic being invoked [2][1].
Citations:
- 1: feat: migrate to Vite+ #2745
- 2: https://github.com/TypeCellOS/BlockNote/blob/main/packages/shadcn/vite.config.ts
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "14-suggestion-gallery" "build:prod"
💡 Result:
The command build:prod is not a standard or documented command within the BlockNote project repository [1]. Based on the codebase, build and deployment tasks are typically managed via pnpm or nx scripts (e.g., pnpm run deploy, nx release) [1], and individual applications or examples often use standard build commands such as next build [2][3] or vite build configurations [4]. If you are attempting to build an application using BlockNote, please note: 1. BlockNote components, including the "suggestion-gallery" or various "suggestion-menu" components, are library-level packages [5][6][7]. They are built as part of the library's internal monorepo workflow, not as standalone production targets with a build:prod script [1]. 2. For your own application, the recommended build process is to use your framework's native build command (e.g., next build for Next.js) [3]. 3. If you encounter errors related to missing modules or build failures after installation, ensure you have correctly installed the necessary @blocknote/* dependencies and that your environment (TypeScript version, etc.) meets the project requirements [3][8]. If "14-suggestion-gallery" refers to a custom folder or component in your local project, you should check your package.json file to see if a build:prod script has been defined there, as it is not a default command provided by the BlockNote framework [1].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/CONTRIBUTING.md
- 2: c9e55cd
- 3: Can not build nextjs app after installing blocknote.js #901
- 4: https://github.com/TypeCellOS/BlockNote/blob/main/examples/07-collaboration/09-comments-testing/vite.config.ts
- 5: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/packages/react/src/components/SuggestionMenu/GridSuggestionMenu/GridSuggestionMenuController.tsx
- 6: refactor: Mentions & custom suggestion menus #534
- 7: https://github.com/TypeCellOS/BlockNote/tree/main/examples/03-ui-components/10-suggestion-menus-grid-mentions
- 8:
Cannot find module '@blocknote/react'warning is VS Code #804
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "Use vp run lint for linting and type-checking"
💡 Result:
The command vp lint is used for linting and type-checking within projects utilizing Vite+ (often referred to as vp), a toolchain that replaces or supplements traditional setups like ESLint and Prettier with faster, Rust-based alternatives such as oxlint [1][2][3][4]. In the context of projects adopting this workflow, linting and type-checking are typically managed as follows: - Linting and Type-Checking: Projects often configure vp lint to execute linting and type-checking tasks [1][2]. This is frequently powered by tools like oxlint (with type-aware linting enabled via tsgolint) [3]. - Configuration: Task definitions are typically handled within the project's vite.config.ts or related configuration files, rather than relying solely on legacy package.json scripts [4]. - CI/CD: In automated workflows, you will commonly see vp lint invoked directly in CI steps (e.g., within GitHub Actions) to ensure code quality [1][2]. While the exact behavior of vp commands can depend on the specific task definitions configured in a project's vite.config.ts, vp lint is the standard command for running these integrated checks [1][2][4].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/blob/c7274dd5e043fccbef0f7c754de881ee47e0c8b4/.github/workflows/build.yml
- 2: https://github.com/TypeCellOS/BlockNote/blob/78277d7ab613bd1a1fd9484972f9e24675f3eef0/.github/workflows/build.yml
- 3: 95f0b93
- 4: feat: migrate to Vite+ #2745
Replace direct tsc invocations in all four build:prod scripts.
Use vp run lint for type-checking. Update the generator, if these scripts are generated, and regenerate the affected examples.
📍 Affects 4 files
examples/03-ui-components/07-suggestion-menus-slash-menu-component/package.json#L10-L10(this comment)examples/03-ui-components/08-suggestion-menus-emoji-picker-columns/package.json#L10-L10examples/07-collaboration/14-suggestion-gallery/package.json#L10-L10examples/08-extensions/01-tiptap-arrow-conversion/package.json#L10-L10
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In
`@examples/03-ui-components/07-suggestion-menus-slash-menu-component/package.json`
at line 10, The four build:prod scripts must use vp run lint instead of invoking
tsc directly. Update the generator responsible for these package scripts, then
regenerate all affected examples:
examples/03-ui-components/07-suggestion-menus-slash-menu-component/package.json
(anchor),
examples/03-ui-components/08-suggestion-menus-emoji-picker-columns/package.json,
examples/07-collaboration/14-suggestion-gallery/package.json, and
examples/08-extensions/01-tiptap-arrow-conversion/package.json; each site
requires the same build:prod command change.
Source: Coding guidelines
| "preview": "vp preview" | ||
| "start": "vite", | ||
| "dev": "vite", | ||
| "build:prod": "tsc && vite build", |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -eu
for f in \
examples/03-ui-components/09-suggestion-menus-emoji-picker-component/package.json \
examples/03-ui-components/10-suggestion-menus-grid-mentions/package.json \
examples/08-extensions/02-versioning/package.json \
examples/09-ai/01-minimal/package.json
do
echo "===== $f ====="
cat -n "$f"
done
echo "===== package-manager and script references ====="
git ls-files | rg '(^|/)(package\.json|vp\.toml|pnpm-workspace\.yaml|pnpm-lock\.yaml|vite\.config\.)$' | head -200
rg -n --glob 'package.json' --glob '!node_modules/**' '"(build:prod|lint|typecheck|check|tsc|vite build)"' .Repository: TypeCellOS/BlockNote
Length of output: 2114
🌐 Web query:
TypeCellOS BlockNote examples/03-ui-components/09-suggestion-menus-emoji-picker-component/package.json build:prod tsc vite
💡 Result:
The directory path "examples/03-ui-components/09-suggestion-menus-emoji-picker-component" in the BlockNote repository contains an example of how to replace the default Emoji Picker component with a custom one [1][2]. Regarding the build command "build:prod tsc vite" referenced in your query: 1. Build Scripts: In the context of BlockNote's example applications, the "build" or "build:prod" scripts are typically defined in the package.json file to compile the code and generate production-ready assets [3][4]. While older configurations often used "tsc && vite build" [4], recent updates to the repository have involved migrating build tasks to Vite-based configurations, sometimes utilizing internal tools like "vite-plus" for more efficient task management [5][6]. 2. Functionality: The specific example you mentioned demonstrates how to disable the default Emoji Picker by passing 'emojiPicker={false}' to the 'BlockNoteView' component and implementing a custom component using the 'GridSuggestionMenuController' [2][7]. For the most accurate and up-to-date configuration for any specific example, you should refer to the 'package.json' and 'vite.config.ts' files located directly within that directory in the official TypeCellOS/BlockNote repository [1].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/tree/main/examples/03-ui-components/09-suggestion-menus-emoji-picker-component
- 2: https://www.blocknotejs.org/examples/ui-components/suggestion-menus-emoji-picker-component
- 3: https://stackblitz.com/edit/github-thjchykw?file=package.json
- 4: m8e@6e1eba2
- 5: feat: migrate to Vite+ #2745
- 6: https://github.com/TypeCellOS/BlockNote/blob/main/examples/07-collaboration/09-comments-testing/vite.config.ts
- 7: https://www.blocknotejs.org/docs/react/components/grid-suggestion-menus
🌐 Web query:
TypeCellOS BlockNote repository coding guidelines "Use vp run lint" tsc
💡 Result:
In the TypeCellOS/BlockNote repository, the current coding and build guidelines emphasize using the Vite+ (vp) toolchain for development tasks rather than invoking individual tools like tsc directly [1][2][3]. As of the recent migration to tsgo for type declarations [1], the repository uses the following conventions: 1. Use vp run lint to perform linting and type checking: The project has enabled type-aware linting (via oxlint and tsgo), which replaces the need for manual tsc calls to verify types during development [1][4][3]. 2. Avoid direct tsc usage: The project has explicitly moved away from tsc for emitting type declarations and type checking in favor of tsgo and the vp toolchain [1]. 3. Adhere to vp commands: Consistent with Vite+ practices, you should use vp commands (e.g., vp run lint, vp run build, vp run test) [5][3]. These commands leverage caching and unified configuration to ensure consistent behavior across the repository [1][5]. For comprehensive status checks, vp check is the recommended command, as it integrates formatting, linting, and type checking efficiently [4][3]. Always prefer the built-in vp task commands over executing wrapped tools like tsc or oxlint directly [6][3].
Citations:
- 1: feat: migrate to tsgo, fix lint warnings, and fix vp build caching #2859
- 2: https://github.com/TypeCellOS/BlockNote/blob/c7274dd5e043fccbef0f7c754de881ee47e0c8b4/.github/workflows/build.yml
- 3: https://github.com/Recappi/sdk/blob/4616c3d0dd2e47f1a8b678f8d131176fab3b6b3e/.github/copilot-instructions.md
- 4: https://viteplus.dev/guide/check
- 5: https://viteplus.dev/guide/run
- 6: https://github.com/miguelspizza/skills/blob/main/tooling/README.md
🌐 Web query:
site:github.com/TypeCellOS/BlockNote/blob/main/examples/03-ui-components/10-suggestion-menus-grid-mentions/package.json "build:prod"
💡 Result:
The build:prod script is:
"build:prod": "tsc && vp build"It runs TypeScript compilation, followed by the Vite Plus production build. (raw.githubusercontent.com)
Citations:
🌐 Web query:
site:github.com/TypeCellOS/BlockNote/blob/main/examples/08-extensions/02-versioning/package.json "build:prod"
💡 Result:
build:prod is defined as:
"build:prod": "tsc && vp build"[1] (raw.githubusercontent.com)
Citations:
🌐 Web query:
site:github.com/TypeCellOS/BlockNote/blob/main/examples/09-ai/01-minimal/package.json "build:prod"
💡 Result:
The build:prod script is:
"build:prod": "tsc && vp build"It runs TypeScript checking/compilation, then builds with Vite Plus. [1]
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "examples/09-ai/01-minimal" "tsc && vite build"
💡 Result:
The command tsc && vite build is a sequence used to build the BlockNote AI minimal example [1][2]. Specifically, this command is found within the package.json file of the examples/09-ai/01-minimal directory in the BlockNote GitHub repository [1][2]. In this context, the command serves the following purposes: 1. tsc: Runs the TypeScript compiler to perform type checking on the code without emitting output files [1][2]. 2. &&: Acts as a logical AND operator, ensuring that the second command (vite build) only executes if the first command (tsc) completes successfully without errors. 3. vite build: Invokes the Vite build tool to bundle the application for production, generating optimized static assets [1][3]. This workflow is part of the standard build process for the BlockNote library's AI-integrated examples [1][4]. The 09-ai/01-minimal example demonstrates the basic setup required to incorporate AI functionality into a BlockNote rich text editor [1].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/tree/main/examples/09-ai/01-minimal
- 2: 838a52d
- 3: feat: migrate to Vite+ #2745
- 4: https://github.com/TypeCellOS/BlockNote/tree/main/examples
🌐 Web query:
site:raw.githubusercontent.com/TypeCellOS/BlockNote/main/examples/03-ui-components/09-suggestion-menus-emoji-picker-component/package.json "build:prod"
💡 Result:
build:prod is defined as:
"build:prod": "tsc && vp build"[1] (raw.githubusercontent.com)
Citations:
🌐 Web query:
site:raw.githubusercontent.com/TypeCellOS/BlockNote/main/examples/03-ui-components/10-suggestion-menus-grid-mentions/package.json "build:prod"
💡 Result:
build:prod is:
"build:prod": "tsc && vp build"[1] (raw.githubusercontent.com)
Citations:
🌐 Web query:
site:raw.githubusercontent.com/TypeCellOS/BlockNote/main/examples/08-extensions/02-versioning/package.json "build:prod"
💡 Result:
build:prod is defined as:
"build:prod": "tsc && vp build"[1] (raw.githubusercontent.com)
Citations:
🌐 Web query:
site:raw.githubusercontent.com/TypeCellOS/BlockNote/main/examples/09-ai/01-minimal/package.json "build:prod"
💡 Result:
The build:prod script is:
"build:prod": "tsc && vp build"[1]
🌐 Web query:
TypeCellOS BlockNote Vite Plus package scripts "vp build" examples build:prod
💡 Result:
In the context of TypeCellOS/BlockNote and its migration to Vite+ (a toolchain by VoidZero), the way scripts are managed has been updated. Vite+ introduces vp as a CLI command to handle development, testing, and production builds [1][2][3]. Regarding the specific terms mentioned: 1. vp build: This is the standard command provided by the Vite+ toolchain to build applications for production [2][4]. It uses the underlying Vite configuration (defined in vite.config.ts) and is designed to replace traditional package.json build scripts [1][4]. 2. build:prod: While projects often contain a build:prod script in their package.json, Vite+ documentation notes that vp build is the native command for production builds [4]. If a project retains a custom build:prod script in package.json, it can be executed using vp run build:prod [5][2]. However, the migration to Vite+ generally involves moving build logic into tasks defined within vite.config.ts to improve caching and performance, rather than relying on legacy package.json scripts [1]. 3. Examples build: The examples directory in the BlockNote repository contains demo projects [6]. With the move to Vite+, these examples are typically handled by the centralized Vite+ configuration, allowing them to benefit from shared caching and dependency tracking [1][6]. In summary, vp build is the primary Vite+ command for production builds [4]. Any legacy build:prod script is now secondary to the unified task runner, and can be executed via vp run if still defined in the local package.json [5][2][4].
Citations:
- 1: feat: migrate to Vite+ #2745
- 2: https://www.npmjs.com/package/vite-plus
- 3: https://voidzero.dev/posts/announcing-vite-plus-beta
- 4: https://viteplus.dev/guide/build
- 5: https://viteplus.dev/config/run
- 6: test: migrate E2E tests to Vitest Browser Mode #2800
Use the approved Vite Plus workflow in all four build:prod scripts.
Replace tsc && vite build with vp build. Run type checking through vp run lint, not from build:prod.
📍 Affects 4 files
examples/03-ui-components/09-suggestion-menus-emoji-picker-component/package.json#L10-L10(this comment)examples/03-ui-components/10-suggestion-menus-grid-mentions/package.json#L10-L10examples/08-extensions/02-versioning/package.json#L10-L10examples/09-ai/01-minimal/package.json#L10-L10
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In
`@examples/03-ui-components/09-suggestion-menus-emoji-picker-component/package.json`
at line 10, Update the build:prod script in
examples/03-ui-components/09-suggestion-menus-emoji-picker-component/package.json:10-10,
examples/03-ui-components/10-suggestion-menus-grid-mentions/package.json:10-10,
examples/08-extensions/02-versioning/package.json:10-10, and
examples/09-ai/01-minimal/package.json:10-10 to use vp build instead of tsc &&
vite build; leave type checking to vp run lint.
Source: Coding guidelines
| "preview": "vp preview" | ||
| "start": "vite", | ||
| "dev": "vite", | ||
| "build:prod": "tsc && vite build", |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
#!/bin/sh
set -eu
printf '%s\n' '--- target package scripts ---'
for f in \
examples/03-ui-components/12-static-formatting-toolbar/package.json \
examples/03-ui-components/13-custom-ui/package.json \
examples/09-ai/05-manual-execution/package.json \
examples/09-ai/06-client-side-transport/package.json
do
printf '\n[%s]\n' "$f"
cat -n "$f"
done
printf '%s\n' '--- repository command configuration ---'
printf '%s\n' '[root package manifests]'
find . -maxdepth 2 -type f \( -name 'package.json' -o -name 'vp.toml' -o -name 'vp.config.*' \) -print
printf '%s\n' '[command-policy references]'
rg -n --hidden -g '!node_modules' -g '!dist' -g '!build' \
'vp run lint|build:prod|standalone|workspace|tsc' \
package.json pnpm-workspace.yaml .github examples 2>/dev/null || true
printf '%s\n' '--- relevant TypeScript and Vite configuration files ---'
for d in \
examples/03-ui-components/12-static-formatting-toolbar \
examples/03-ui-components/13-custom-ui \
examples/09-ai/05-manual-execution \
examples/09-ai/06-client-side-transport
do
printf '\n[%s]\n' "$d"
find "$d" -maxdepth 2 -type f \( -name 'tsconfig*.json' -o -name 'vite.config.*' \) -print
doneRepository: TypeCellOS/BlockNote
Length of output: 2114
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "examples/03-ui-components/12-static-formatting-toolbar/package.json" "build:prod"
💡 Result:
The file examples/03-ui-components/12-static-formatting-toolbar/package.json is a configuration file located within the examples directory of the BlockNote library repository [1][2]. This specific example demonstrates how to implement a static formatting toolbar, where the developer controls the position and visibility of the toolbar manually rather than using the default automatic controller [3][4]. Regarding the build:prod command, modern versions of the BlockNote repository have migrated to a Vite-based build system (often referred to as Vite+) [5]. In this updated architecture, many package.json build scripts have been transitioned to tasks defined within the respective vite.config.ts files to improve cache management and avoid broad input tracking [5][6]. Consequently, if a build:prod command exists in that specific package.json, it is likely a legacy or specific helper script that invokes build processes (such as tsc or specific Vite tasks) [5][6]. In the current repository structure, you should check the package's vite.config.ts or the root workspace configuration for the definitive build task definitions [5][6].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/tree/main/examples/03-ui-components
- 2: https://github.com/TypeCellOS/BlockNote/tree/main/examples
- 3: When using <FormattingToolbar>, double-clicking at end of a line causes fatal error #1115
- 4: docs: Updated custom UI example #926
- 5: feat: migrate to Vite+ #2745
- 6: https://github.com/TypeCellOS/BlockNote/blob/main/packages/shadcn/vite.config.ts
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "vp run lint" "build:prod"
💡 Result:
The command vp run lint build:prod is not a standard or globally recognized command for the vp (VoidZero) tool. Rather, it appears to be a specific sequence of commands, or a custom task, used within projects (notably the BlockNote repository) that utilize the VoidZero-based development environment [1][2]. In the context of the projects where this tooling is used: 1. vp: This is the command-line interface tool for VoidZero [1][2]. It manages dependencies and task execution, often serving as a replacement for package managers like pnpm in these specific environments [3][4]. 2. run: This is the primary command used by vp to execute tasks defined in the configuration, such as build, test, or lint [5][1]. 3. lint and build:prod: These are task names. In the workflow of these specific projects, build tasks (like build:prod) are often configured with output paths to ensure artifacts are cached and available for downstream tasks like linting [6][7][8]. It is common practice in these environments to execute the build step before linting, especially when type-aware linting is required, as the linter needs the compiled type declarations generated by the build process to resolve cross-package imports [6]. If you are working in a repository that uses this tool, you would typically define these tasks in your configuration files and execute them individually or via a script that chains them together.
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/blob/c7274dd5e043fccbef0f7c754de881ee47e0c8b4/.github/workflows/build.yml
- 2: https://github.com/TypeCellOS/BlockNote/blob/33242468bcc08ca737b595027944106df5e35580/.github/workflows/build.yml
- 3: b902dbb
- 4: 878411e
- 5: https://github.com/TypeCellOS/BlockNote/blob/ade62f2b360a35629a376aa2d3de71cb06719872/.github/workflows/fresh-install-tests.yml
- 6: 729a3d2
- 7: feat: migrate to tsgo, fix lint warnings, and fix vp build caching #2859
- 8: 9fb13a7
🏁 Script executed:
#!/bin/sh
set -eu
base='https://raw.githubusercontent.com/TypeCellOS/BlockNote/7a78484b71eafbf00bb699a0acb32230ca37d7a0'
for path in \
examples/03-ui-components/12-static-formatting-toolbar/package.json \
examples/03-ui-components/13-custom-ui/package.json \
examples/09-ai/05-manual-execution/package.json \
examples/09-ai/06-client-side-transport/package.json \
package.json \
pnpm-workspace.yaml \
vp.toml \
vp.config.ts \
vp.config.js
do
printf '\n--- %s ---\n' "$path"
curl -fsSL "$base/$path" || printf '%s\n' '(not present)'
doneRepository: TypeCellOS/BlockNote
Length of output: 2114
🌐 Web query:
"7a78484b71eafbf00bb699a0acb32230ca37d7a0" "build:prod" BlockNote
💡 Result:
The string 7a78484b71eafbf00bb699a0acb32230ca37d7a0 appears to be a random hexadecimal hash, likely a Git commit hash or internal identifier, and does not correspond to an official command or configuration key in BlockNote [1][2]. Regarding build:prod, while some community examples or secondary integrations may use custom npm scripts like "build:prod": "tsc && vite build" [3], the official BlockNote monorepo uses Nx as its primary task orchestration tool [2]. The standard build command in the official repository is pnpm run build (which executes nx run-many --target=build) or specific package-level builds [2]. If you are encountering issues where a production build (via vite build) results in a non-functional editor, ensure that your build configuration correctly handles dependencies and environment-specific aliases [4][5]. Official documentation recommends following the setup provided in the repository's build pipeline or standard quickstart guides to avoid configuration errors [1][2].
Citations:
- 1: https://github.com/typecellos/blocknote
- 2: https://deepwiki.com/TypeCellOS/BlockNote/11.2-build-pipeline
- 3: https://stackblitz.com/edit/github-thjchykw?file=package.json
- 4: https://github.com/TypeCellOS/BlockNote/blob/main/packages/shadcn/vite.config.ts
- 5: BlockNote editor renders but does NOT accept user input in production build (Vite + Rollup) #2925
Replace direct tsc calls in all four build:prod scripts.
Use vp run lint for type-checking. Do not invoke tsc directly.
📍 Affects 4 files
examples/03-ui-components/12-static-formatting-toolbar/package.json#L10-L10(this comment)examples/03-ui-components/13-custom-ui/package.json#L10-L10examples/09-ai/05-manual-execution/package.json#L10-L10examples/09-ai/06-client-side-transport/package.json#L10-L10
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@examples/03-ui-components/12-static-formatting-toolbar/package.json` at line
10, Replace the direct tsc invocation in the build:prod script with vp run lint
before vite build in all affected package files:
examples/03-ui-components/12-static-formatting-toolbar/package.json (anchor,
line 10), examples/03-ui-components/13-custom-ui/package.json (sibling, line
10), examples/09-ai/05-manual-execution/package.json (sibling, line 10), and
examples/09-ai/06-client-side-transport/package.json (sibling, line 10).
Source: Coding guidelines
| "preview": "vp preview" | ||
| "start": "vite", | ||
| "dev": "vite", | ||
| "build:prod": "tsc && vite build", |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win
Remove direct tsc from the standalone build scripts.
All four scripts invoke tsc, but the repository rule requires vp run lint for linting and type-checking and prohibits direct tsc.
examples/03-ui-components/16-link-toolbar-buttons/package.json#L10-L10: remove directtscfrombuild:prod, or run the approved check outside the standalone script.examples/vanilla-js/react-vanilla-custom-inline-content/package.json#L10-L10: remove directtscfrombuild:prod, or run the approved check outside the standalone script.examples/vanilla-js/react-vanilla-custom-styles/package.json#L10-L10: remove directtscfrombuild:prod, or run the approved check outside the standalone script.examples/vanilla-js/vanilla-custom-side-menu/package.json#L10-L10: remove directtscfrombuild:prod, or run the approved check outside the standalone script.
📍 Affects 4 files
examples/03-ui-components/16-link-toolbar-buttons/package.json#L10-L10(this comment)examples/vanilla-js/react-vanilla-custom-inline-content/package.json#L10-L10examples/vanilla-js/react-vanilla-custom-styles/package.json#L10-L10examples/vanilla-js/vanilla-custom-side-menu/package.json#L10-L10
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@examples/03-ui-components/16-link-toolbar-buttons/package.json` at line 10,
Remove the direct tsc invocation from the build:prod script in
examples/03-ui-components/16-link-toolbar-buttons/package.json (line 10),
examples/vanilla-js/react-vanilla-custom-inline-content/package.json (line 10),
examples/vanilla-js/react-vanilla-custom-styles/package.json (line 10), and
examples/vanilla-js/vanilla-custom-side-menu/package.json (line 10); keep
production builds using the approved workflow, with linting and type-checking
performed through vp run lint outside these standalone scripts.
Source: Coding guidelines
| "preview": "vp preview" | ||
| "start": "vite", | ||
| "dev": "vite", | ||
| "build:prod": "tsc && vite build", |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟠 Major | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -eu
printf '%s\n' '--- target manifests ---'
for f in \
examples/03-ui-components/19-suggestion-menus-grouping-ordering/package.json \
examples/03-ui-components/20-portal-elements/package.json \
examples/04-theming/01-theming-dom-attributes/package.json \
examples/04-theming/02-changing-font/package.json
do
printf '\n[%s]\n' "$f"
cat -n "$f"
done
printf '%s\n' '--- repository command guidance ---'
rg -n --hidden -g '!node_modules' -g '!dist' -g '!build' \
'vp run lint|build:prod|tsc && vite build|standalone|generated examples' \
. | head -n 240
printf '%s\n' '--- nearby example scripts ---'
find examples -name package.json -type f -print0 |
xargs -0 grep -nE '"(build:prod|lint|typecheck|build)"' |
head -n 240Repository: TypeCellOS/BlockNote
Length of output: 2114
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "examples/03-ui-components/19-suggestion-menus-grouping-ordering/package.json"
💡 Result:
The file located at examples/03-ui-components/19-suggestion-menus-grouping-ordering/package.json is part of the BlockNote open-source project, a block-based text editor framework [1][2]. This specific path serves as an example component demonstrating how to implement grouping and ordering in suggestion menus within the editor [2]. As an example project file, its package.json typically defines the dependencies and scripts required to run that specific UI component example in isolation or as part of the broader BlockNote documentation and example suite [1][3][4]. The repository history indicates that this file is regularly updated alongside the project's build infrastructure, such as migrations to Vite and other toolchain updates [1][3][5][6]. You can view the current contents and structure of this file directly in the BlockNote GitHub repository [2].
Citations:
- 1: feat: migrate to Vite+ #2745
- 2: https://github.com/TypeCellOS/BlockNote/tree/main/examples/03-ui-components/19-suggestion-menus-grouping-ordering
- 3: 767a82f
- 4: bb6ead5
- 5: feat: migrate to tsgo, fix lint warnings, and fix vp build caching #2859
- 6: 95f0b93
🌐 Web query:
site:github.com/TypeCellOS/BlockNote "vp run lint" "build:prod"
💡 Result:
The command vp run lint build:prod is not a single, standard command in the vp tool (VoidZero's monorepo management tool) [1][2]. Based on the usage patterns in the BlockNote project, vp uses the run command to execute tasks defined in the workspace, such as vp run build or vp run test [3][4][1]. If you intend to run both linting and a production build, these would typically be executed as separate commands or configured as a composite task in your project's configuration [4][1]. For example, to run both in sequence, you might use: vp run lint && vp run build:prod Key details about using vp: - Task Execution: Tasks are triggered using vp run [3][4]. - Caching: The vp tool is designed to cache task outputs, such as build artifacts [4][5][6]. - Order of Operations: In many TypeScript monorepos, it is often necessary to run build tasks before linting (specifically type-aware linting) to ensure that the linter can resolve cross-package imports and compiled type declarations [7]. - Configuration: You should verify the specific task names available in your project's configuration files (often managed by the vp-related settings) to confirm if build:prod is a defined script [4].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/blob/78277d7ab613bd1a1fd9484972f9e24675f3eef0/.github/workflows/build.yml
- 2: https://github.com/TypeCellOS/BlockNote/blob/33242468bcc08ca737b595027944106df5e35580/.github/workflows/build.yml
- 3: https://github.com/TypeCellOS/BlockNote/blob/ade62f2b360a35629a376aa2d3de71cb06719872/.github/workflows/fresh-install-tests.yml
- 4: feat: migrate to tsgo, fix lint warnings, and fix vp build caching #2859
- 5: 41df112
- 6: 9fb13a7
- 7: 729a3d2
🏁 Script executed:
#!/bin/bash
set -eu
base='https://raw.githubusercontent.com/TypeCellOS/BlockNote/main'
files=(
'examples/03-ui-components/19-suggestion-menus-grouping-ordering/package.json'
'examples/03-ui-components/20-portal-elements/package.json'
'examples/04-theming/01-theming-dom-attributes/package.json'
'examples/04-theming/02-changing-font/package.json'
'package.json'
'pnpm-workspace.yaml'
)
for file in "${files[@]}"; do
printf '\n--- %s ---\n' "$file"
curl --fail --silent --show-error "$base/$file" | sed -n '1,160p'
done
printf '\n--- repository references to the target scripts ---\n'
curl --fail --silent --show-error \
'https://api.github.com/search/code?q=repo%3ATypeCellOS%2FBlockNote+%22tsc+%26%26+vite+build%22' |
grep -E '"path"|"html_url"' | head -n 80Repository: TypeCellOS/BlockNote
Length of output: 2114
🌐 Web query:
site:github.com/TypeCellOS/BlockNote/blob "build:prod" "tsc && vite build" "20-portal-elements"
💡 Result:
The command "build:prod tsc && vite build 20-portal-elements" is a sequence of shell operations commonly found in JavaScript or TypeScript monorepo build pipelines, specifically within the TypeCellOS/BlockNote ecosystem [1][2]. Breakdown of the command: 1. build:prod: This is a user-defined script alias, typically configured in a package.json file. It likely triggers a production-optimized build process for the project or package. 2. tsc: This invokes the TypeScript Compiler to perform type checking or compilation [1]. It ensures that the code adheres to TypeScript definitions before the build proceeds. 3. &&: This logical operator ensures that the subsequent command (vite build) only executes if the preceding command (tsc) completes successfully without errors. 4. vite build 20-portal-elements: This command instructs Vite to perform a production build [1][2]. While "20-portal-elements" is not a standard Vite flag, in this context it refers to a specific project, package, or entry point within the monorepo that Vite is being directed to bundle [1][2]. In the context of the TypeCellOS/BlockNote codebase, such patterns are often handled by "vp" (a tool associated with VoidZero/Vite-based workflows) to orchestrate build tasks across monorepo workspaces [2][3]. If you are encountering this command, it is intended to perform a type-checked production build of the specified target package.
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/blob/main/packages/shadcn/vite.config.ts
- 2: https://github.com/TypeCellOS/BlockNote/blob/main/packages/xl-ai/vite.config.ts
- 3: https://github.com/TypeCellOS/BlockNote/blob/c7274dd5e043fccbef0f7c754de881ee47e0c8b4/.github/workflows/build.yml
🌐 Web query:
site:github.com/TypeCellOS/BlockNote/blob "build:prod" "tsc && vite build" "01-theming-dom-attributes"
💡 Result:
The command build:prod tsc && vite build is a sequence of two commands used to build a project, typically found in a package.json file [1][2]. The tsc part invokes the TypeScript compiler to check types and/or emit JavaScript files based on your tsconfig.json, while vite build invokes the Vite bundler to perform the production build of your application or library [1][2]. The string 01-theming-dom-attributes refers to a specific topic within the BlockNote documentation, titled Adding DOM Attributes [3]. This documentation explains how to add custom attributes to the DOM elements of the BlockNote editor [3]. In the context of the BlockNote codebase, which uses these commands, domAttributes can be configured as follows: { domAttributes: { editor: { class: "my-editor-class", id: "my-editor-id" } } } This configuration allows you to inject custom classes, IDs, or other attributes directly into the rendered editor elements, which is useful for styling or integration purposes [3]. You can find further details in the official BlockNote documentation regarding theming and DOM attribute management [3].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/blob/main/packages/shadcn/vite.config.ts
- 2: https://github.com/TypeCellOS/BlockNote/blob/main/packages/xl-ai/vite.config.ts
- 3: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/packages/core/src/editor/BlockNoteEditor.ts
🌐 Web query:
site:github.com/TypeCellOS/BlockNote/blob "build:prod" "tsc && vite build" "02-changing-font"
💡 Result:
The command tsc && vite build is a sequential execution of two distinct build processes commonly used in JavaScript and TypeScript projects [1]. tsc: This invokes the TypeScript Compiler. It performs type-checking on your project's TypeScript files to ensure there are no type errors [1]. If the type-checking fails, the command will exit with an error, preventing the subsequent build step from running [1]. vite build: This invokes the Vite bundler to perform the actual production build of your application [2][1]. Vite compiles, minifies, and optimizes your code (including assets, modules, and dependencies) for production deployment [2][3]. The && operator ensures that vite build only executes if tsc completes successfully (i.e., the exit code of the first command is 0), ensuring that you do not produce a production build from broken or type-incorrect code [1]. In the context of the TypeCellOS/BlockNote repository, this pattern is used as a standard build script to maintain codebase integrity [1][4]. The build:prod prefix is a naming convention often defined in a package.json file to identify a production-grade build task [5]. The 02-changing-font mentioned in your query likely refers to a specific example directory or test case within that repository where such a build command might be executed as part of a demonstration or verification process [2][1].
Citations:
- 1: https://github.com/TypeCellOS/BlockNote/blob/main/packages/shadcn/vite.config.ts
- 2: https://github.com/TypeCellOS/BlockNote/blob/main/examples/07-collaboration/09-comments-testing/vite.config.ts
- 3: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/packages/mantine/vite.config.ts
- 4: https://github.com/TypeCellOS/BlockNote/blob/main/packages/xl-ai/vite.config.ts
- 5: https://github.com/TypeCellOS/BlockNote/blob/ba03b7d2/.github/workflows/build.yml
Use vp run lint instead of direct tsc in all four build:prod scripts.
If the examples cannot invoke vp independently, move type-checking to monorepo validation and keep build:prod as vite build.
📍 Affects 4 files
examples/03-ui-components/19-suggestion-menus-grouping-ordering/package.json#L10-L10(this comment)examples/03-ui-components/20-portal-elements/package.json#L10-L10examples/04-theming/01-theming-dom-attributes/package.json#L10-L10examples/04-theming/02-changing-font/package.json#L10-L10
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@examples/03-ui-components/19-suggestion-menus-grouping-ordering/package.json`
at line 10, Replace the direct tsc invocation in the build:prod scripts with vp
run lint across
examples/03-ui-components/19-suggestion-menus-grouping-ordering/package.json:10-10,
examples/03-ui-components/20-portal-elements/package.json:10-10,
examples/04-theming/01-theming-dom-attributes/package.json:10-10, and
examples/04-theming/02-changing-font/package.json:10-10. If vp cannot run
independently in these examples, remove type-checking from each build:prod
script so it runs only vite build, relying on monorepo validation for
type-checking.
Source: Coding guidelines
Summary
Use plain
viteinstead ofvite-plusin generated standalone examples so they work in StackBlitz's WebContainers environment.Fixes #2916
Rationale
vite-plusrequires platform-specific native NAPI-RS bindings (.nodefiles) that cannot run in StackBlitz's WebContainers (a browser-based Node.js runtime). This causes every example StackBlitz link to crash with"Cannot find native binding". VoidZero has scaffolded a WASM fallback (@voidzero-dev/vite-plus-wasm32-wasi) in their binding loader but hasn't published it yet, and it's not on their Q3 2026 roadmap.The examples only use standard Vite features (
defineConfig, dev server, build) — none of the vite-plus extras (oxlint, oxfmt, task runner) — so plainviteis fully sufficient.Changes
package.json.template.tsx,vite.config.ts.template.tsx,vite-env.d.ts.template.tsx) to useviteinstead ofvite-plusvp dev/vp build/vp previewtovite/vite build/vite previewvite: ^8.0.0to the pnpm workspace catalogImpact
vite-plusfor development — only the standalone examples changenpm install && npm run devTesting
npm install && npm run devworks for both the minimal example and the shadcn/tailwind example in isolated temp directories outside the monorepovite buildsucceeds standalonevp run buildpasses for the full projectvp run gen --forceproduces stable output (changes survive regeneration)Checklist
Summary by CodeRabbit