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

fix(astro): inject duplicate style #2593

Merged
merged 8 commits into from
May 21, 2023
Merged

Conversation

Dunqing
Copy link
Member

@Dunqing Dunqing commented May 9, 2023

fix: #2513

Avoid inject styles in non-ssr

@Dunqing Dunqing requested a review from antfu as a code owner May 9, 2023 03:39
@netlify
Copy link

netlify bot commented May 9, 2023

Deploy Preview for unocss ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 0092917
🔍 Latest deploy log https://app.netlify.com/sites/unocss/deploys/6461e8869264b70007fa3b64
😎 Deploy Preview https://deploy-preview-2593--unocss.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

packages/vite/src/modes/global/dev.ts Outdated Show resolved Hide resolved
@Dunqing Dunqing requested a review from antfu May 9, 2023 13:24
import type { Plugin } from 'vite'

const UNO_INJECT_ID = 'uno-astro'
const UNO_QUERY_KEY = 'uwa'
Copy link
Member

Choose a reason for hiding this comment

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

What does uwa mean? Can we use a longer and more descriptive name?

Copy link
Member Author

Choose a reason for hiding this comment

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

I used uno-with-astro-key instead of uwa, do you think that would work?

Also, the UNO_QUERY_KEY will be displayed on the url
image

@antfu antfu merged commit e6b0d71 into unocss:main May 21, 2023
10 checks passed
@antfu antfu mentioned this pull request May 22, 2023
4 tasks
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.

Duplicate styles injected when using Astro integration
2 participants