Skip to content

DX issue: Using a prefix in v4 requires two actions for a completion #1291

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

Closed
thecrypticace opened this issue Apr 1, 2025 · 0 comments · Fixed by #1292
Closed

DX issue: Using a prefix in v4 requires two actions for a completion #1291

thecrypticace opened this issue Apr 1, 2025 · 0 comments · Fixed by #1292
Assignees

Comments

@thecrypticace
Copy link
Contributor

The quickest way for IntelliSense to support the "variant-style" prefix was to treat it as a fake variant and make some tweaks to how and what completions we show. This has an unfortunate side effect of requiring a "double action" whenever typing new classes. We should instead, when no class has been typed yet:

  • Offer the prefix as a fake variant like we do today
  • Show variants like normal but prefix them with the fake variant so they'll look like tw:md: in the suggestions
  • Show classes like normal but prefix them with the fake variant so they'll look like tw:underline in the suggestions

None of this need apply if the variant is already typed nor if the user has typed a class name that does not begin with the variant-style prefix.

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 a pull request may close this issue.

1 participant