Skip to content

Conversation

@alexgrozav
Copy link
Contributor

This pull request refactors the dependency management across all Styleframe packages to use peer dependencies instead of direct dependencies, and updates documentation and tooling to reflect these changes. The goal is to improve tree-shaking, version control, and modularity for consumers of the Styleframe ecosystem.

Dependency management refactor:

  • Updated package.json files for @styleframe/core, @styleframe/loader, @styleframe/transpiler, and @styleframe/cli to move internal Styleframe packages from dependencies to peerDependencies, ensuring that consumers explicitly install required packages and improving compatibility. [1] [2] [3] [4] [5]

Documentation updates:

  • Revised installation instructions in Vite, Nuxt, and custom setup docs to list all Styleframe packages as required development dependencies, clarifying the modular release strategy. [1] [2] [3]

Tooling update:

  • Modified the addPackageJsonDependencies function in tooling/cli/src/commands/init.ts to add all Styleframe packages as development dependencies during project initialization, matching the new peer dependency structure.

These changes collectively streamline how Styleframe packages are consumed and managed, making the ecosystem more flexible and maintainable.

@alexgrozav alexgrozav requested a review from Copilot November 21, 2025 06:51
@alexgrozav alexgrozav self-assigned this Nov 21, 2025
@changeset-bot
Copy link

changeset-bot bot commented Nov 21, 2025

🦋 Changeset detected

Latest commit: 504a21c

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 7 packages
Name Type
@styleframe/transpiler Major
@styleframe/loader Major
@styleframe/core Minor
@styleframe/cli Major
styleframe Major
@styleframe/theme Major
@styleframe/plugin Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@vercel
Copy link

vercel bot commented Nov 21, 2025

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

Project Deployment Preview Comments Updated (UTC)
app-styleframe-dev-production Ready Ready Preview Comment Nov 21, 2025 8:57am
styleframe-dev-production Ready Ready Preview Comment Nov 21, 2025 8:57am

Copy link
Contributor

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 refactors the Styleframe monorepo to use peer dependencies instead of direct dependencies for internal packages, improving modularity and allowing consumers to have better control over package versions. The changes ensure that all Styleframe packages are explicitly installed by consumers rather than being bundled transitively.

Key Changes:

  • Moved internal Styleframe package dependencies to peerDependencies in @styleframe/core, @styleframe/loader, @styleframe/transpiler, and @styleframe/cli, while maintaining them in devDependencies for local development
  • Updated all installation documentation to list all nine Styleframe packages (styleframe, @styleframe/cli, @styleframe/core, @styleframe/license, @styleframe/loader, @styleframe/plugin, @styleframe/pro, @styleframe/theme, @styleframe/transpiler)
  • Modified the CLI init command to add all Styleframe packages as development dependencies with consistent ^2.0.0 version ranges

Reviewed Changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
engine/core/package.json Moved @styleframe/license from dependencies to peerDependencies, added to devDependencies
engine/loader/package.json Moved @styleframe/core, @styleframe/license, and @styleframe/transpiler to peerDependencies, kept c12 in dependencies
engine/transpiler/package.json Moved @styleframe/core and @styleframe/license to peerDependencies, kept scule in dependencies
tooling/cli/package.json Moved @styleframe/loader to peerDependencies while keeping in devDependencies
tooling/cli/src/commands/init.ts Expanded package installation to include all nine Styleframe packages in alphabetical order
apps/docs/.../vite.md Updated installation instructions to list all Styleframe packages with explanatory text
apps/docs/.../nuxt.md Updated installation instructions to list all Styleframe packages
apps/docs/.../custom.md Updated installation instructions to list all Styleframe packages with explanatory text
.changeset/famous-feet-look.md Added changeset documenting the peer dependency refactor for affected packages

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

### Install styleframe in your project

Install `styleframe`, `@styleframe/theme`, and `@styleframe/pro` as development dependencies to your project.
Install `styleframe`, `@styleframe/cli`, `@styleframe/core`, `@styleframe/license`, `@styleframe/loader`, `@styleframe/plugin`, `@styleframe/pro`, `@styleframe/theme`, and `@styleframe/transpiler` as development dependencies to your project.
Copy link

Copilot AI Nov 21, 2025

Choose a reason for hiding this comment

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

The installation instruction text is inconsistent with the other documentation files (vite.md and custom.md). Consider using the same wording for consistency:

"Install all styleframe packages as development dependencies to your project. We've released each package separately to allow for better tree-shaking and version control."

This matches the description in the Vite and custom setup documentation.

Suggested change
Install `styleframe`, `@styleframe/cli`, `@styleframe/core`, `@styleframe/license`, `@styleframe/loader`, `@styleframe/plugin`, `@styleframe/pro`, `@styleframe/theme`, and `@styleframe/transpiler` as development dependencies to your project.
Install all styleframe packages as development dependencies to your project. We've released each package separately to allow for better tree-shaking and version control.

Copilot uses AI. Check for mistakes.
@codecov
Copy link

codecov bot commented Nov 21, 2025

Codecov Report

❌ Patch coverage is 0% with 7 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
tooling/cli/src/commands/init.ts 0.00% 7 Missing ⚠️

📢 Thoughts on this report? Let us know!

@alexgrozav alexgrozav merged commit 1fd348e into main Nov 21, 2025
10 of 11 checks passed
@alexgrozav alexgrozav deleted the peerDependencies branch November 21, 2025 09:06
This was referenced Nov 21, 2025
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