Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: vite plugin (5.x) #2935

Open
wants to merge 6 commits into
base: 5.x
Choose a base branch
from
Open

feat: vite plugin (5.x) #2935

wants to merge 6 commits into from

Conversation

tomrav
Copy link
Collaborator

@tomrav tomrav commented Jan 2, 2024

A Stylable integration plugin for vite.

Currently does not include a CSA template.

Copy link
Collaborator

@idoros idoros left a comment

Choose a reason for hiding this comment

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

there are several upgrades and fixes the rollup integration has had since this was copied, it might be worth it to migrate these changes

clearScreen: false,
};

async function viteBuildAndPreview() {
Copy link
Collaborator

Choose a reason for hiding this comment

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

would be nice to extract to a basic test-kit to share between the 2 specs

"!*/tsconfig.{json,tsbuildinfo}"
],
"engines": {
"node": ">=16"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
"node": ">=16"
"node": ">=18.12.0"

Plugin['transform'] extends ObjectHook<infer T, {}> ? NonNullable<T> : false
>;

export function generateStylableModuleCode(
Copy link
Collaborator

Choose a reason for hiding this comment

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

notice that on master this was refactored to a common place between integrations

* string - it will use the provided string as the "stcConfig" file path.
*/
stcConfig?: boolean | string;
projectRoot?: string;
Copy link
Collaborator

Choose a reason for hiding this comment

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

the rollup integration this was copied from now supports a better default for handling side-effects: includeGlobalSideEffects

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.

None yet

3 participants