jantimon / next-yak

a streamlined CSS-in-JS solution tailor-made for Next.js, seamlessly combining the expressive power of styled-components syntax with efficient build-time extraction and minimal runtime footprint, ensuring optimal performance and easy integration with existing atomic CSS frameworks like Tailwind CSS
https://yak.js.org
108 stars 2 forks source link

experimental flag to transpile styled-components to next-yak #113

Open jantimon opened 1 month ago

jantimon commented 1 month ago

Maybe we could add an experimental flag in the withYak config to automatically transpile styled-components code to next-yak. This feature would allow users to easily test existing styled-components-based projects with next-yak, potentially identifying performance improvements and compatibility issues.

Benefits:

  1. Easier migration path for existing styled-components projects
  2. Quick performance comparison between styled-components and next-yak
  3. Identify areas where next-yak might need additional features to fully support styled-components syntax

Proposed Implementation:

Mad-Kat commented 1 month ago

At the moment we don't support 100% of all features that styled-components has. Is the idea to somehow bail out if we find something that we don't support or just generate a warning?