Skip to content

Update Prerequisites + initial @code-blocks/registry package#16

Merged
pheralb merged 5 commits intomainfrom
next
Mar 7, 2026
Merged

Update Prerequisites + initial @code-blocks/registry package#16
pheralb merged 5 commits intomainfrom
next

Conversation

@pheralb
Copy link
Owner

@pheralb pheralb commented Mar 7, 2026

No description provided.

@pheralb pheralb requested a review from Copilot March 7, 2026 18:53
@vercel
Copy link

vercel bot commented Mar 7, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
code-blocks Ready Ready Preview, Comment Mar 7, 2026 6:53pm

@pheralb pheralb merged commit 5b38172 into main Mar 7, 2026
7 checks passed
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR introduces a new internal @code-blocks/registry workspace package to centralize registry-related TypeScript types, updates the website to consume those shared types, and expands the docs with shadcn/ui registry setup instructions.

Changes:

  • Add initial packages/registry package (types + build/lint tooling via tsdown/eslint).
  • Update the website to import registry types from @code-blocks/registry and wire up TS path mapping + dependency.
  • Extend “Prerequisites” docs with a shadcn/ui registry section.

Reviewed changes

Copilot reviewed 12 out of 13 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
pnpm-lock.yaml Adds the new workspace package plus new toolchain dependencies (tsdown/rolldown, etc.).
packages/registry/tsdown.config.ts Defines tsdown build entries for the new registry package.
packages/registry/tsconfig.json TypeScript configuration for the new registry package.
packages/registry/src/types/index.ts Introduces shared registry-related type definitions.
packages/registry/src/index.ts Package entry point re-exporting registry types.
packages/registry/package.json Declares the new package, exports, and build/dev scripts.
packages/registry/eslint.config.ts Adds package-level ESLint config based on the shared base config.
packages/eslint/configs/base.ts Disables turbo/no-undeclared-env-vars in the shared ESLint base config.
apps/website/tsconfig.json Adds a TS paths mapping to consume @code-blocks/registry from source.
apps/website/src/types/registry.ts Replaces local registry type definitions with the shared base type from @code-blocks/registry.
apps/website/src/docs/getting-started/prerequisites.mdx Adds shadcn/ui registry instructions.
apps/website/src/components/registry/build-registry.ts Switches to importing ShadcnRegistry from the shared package; minor log formatting change.
apps/website/package.json Adds @code-blocks/registry as a workspace dev dependency.
Files not reviewed (1)
  • pnpm-lock.yaml: Language not supported

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

"type": "module",
"version": "0.0.0",
"private": true,
"license": "MIT",
Copy link

Copilot AI Mar 7, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This package adds build tooling (tsdown) that requires Node >=20.19.0 (per lockfile). Consider adding an explicit engines.node constraint here (and/or at the workspace root) so consumers and CI fail fast with a clear message instead of a confusing install/build error.

Suggested change
"license": "MIT",
"license": "MIT",
"engines": {
"node": ">=20.19.0"
},

Copilot uses AI. Check for mistakes.
@@ -0,0 +1 @@
export * from "./types";
Copy link

Copilot AI Mar 7, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

export * from "./types" will emit a runtime re-export, which can break under Node ESM because ./types is a directory/extensionless specifier (and this package currently only contains type exports). Consider making this a type-only re-export (so no runtime import is emitted) or re-exporting the concrete file path that will exist in dist.

Suggested change
export * from "./types";
export type * from "./types";

Copilot uses AI. Check for mistakes.
@@ -8,7 +8,6 @@ To create your own custom Code Block component, make sure you have the following

- [Node.js v20](https://nodejs.org/en/download/current) or higher.
Copy link

Copilot AI Mar 7, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The prerequisites state Node.js v20+, but the newly introduced tooling (e.g. tsdown@0.20.3) requires Node >=20.19.0 (per pnpm-lock.yaml). Please update this prerequisite to the actual minimum supported Node version to avoid install/build failures on early Node 20 releases.

Suggested change
- [Node.js v20](https://nodejs.org/en/download/current) or higher.
- [Node.js v20.19.0](https://nodejs.org/en/download/current) or higher.

Copilot uses AI. Check for mistakes.

## shadcn/ui

[shadcn/ui](https://ui.shadcn.com/) is a collection of accessible and customizable UI components styled with Tailwind CSS. It provides a CLI that you can use it to add components to your project using the [`components.json`](https://ui.shadcn.com/docs/components-json) file.
Copy link

Copilot AI Mar 7, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Grammar: “It provides a CLI that you can use it to add…” has an extra “it”. Consider rephrasing to “...you can use to add…” for readability.

Suggested change
[shadcn/ui](https://ui.shadcn.com/) is a collection of accessible and customizable UI components styled with Tailwind CSS. It provides a CLI that you can use it to add components to your project using the [`components.json`](https://ui.shadcn.com/docs/components-json) file.
[shadcn/ui](https://ui.shadcn.com/) is a collection of accessible and customizable UI components styled with Tailwind CSS. It provides a CLI that you can use to add components to your project using the [`components.json`](https://ui.shadcn.com/docs/components-json) file.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants