Skip to content

Handle an async design system #1031

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

Merged
merged 1 commit into from
Aug 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,11 @@ export async function loadDesignSystem(
let resolved = await resolveCssImports().process(css, { from: filepath })

// Step 3: Take the resolved CSS and pass it to v4's `loadDesignSystem`
let design = tailwindcss.__unstable__loadDesignSystem(resolved.css) as DesignSystem
let design: DesignSystem = await tailwindcss.__unstable__loadDesignSystem(resolved.css, {
loadPlugin() {
return () => {}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

We're intentionally not handling @plugin here — this PR is purely to make sure alpha 19 doesn't break in intellisense. That support will be done in a separate PR.

},
})

// Step 4: Augment the design system with some additional APIs that the LSP needs
Object.assign(design, {
Expand Down