-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Add getThemeEntries API
#15294
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
Add getThemeEntries API
#15294
Conversation
|
@thecrypticace The way this is implement now, were just moving a hardcoded list from the intellisense repo to core but the list is still hardcoded and will likely go out of sync easily, or am I missing something here? 🤔
I'd say if it fixes an issue that users are seeing then yeah but to my understanding this won't do anything unless you also update intellisense? |
|
Yes we're moving the list into core even if it's hardcoded right now. So while we could miss something we at least have an avenue to update it in a new beta release. I did update some of the entries (we should double check to see which ones we want to include / change / whatever).
That is correct. |
|
@thecrypticace Forgive me stupidity but it's unclear what problem this is really solving? I don't think we're currently planning on making any more changes to the variables and adding an allow list in core just because it might seems a bit much especially since it's still fixable by updating the intellisense extension anyways? Since this is referenced in the |
|
I can just update the hardcoded list in IntelliSense instead if we want to. But the goal was to allow control from core. Whether we're going to update the list or not (I could see us adding entries to the list because what we have right now was cherry picked based on the default theme). The API would in theory allow us to tailor the suggestions based on the current state of the theme in the future. For example, if we wanted to suggest I would like to, as much as possible, eliminate hardcoded data from IntelliSense. |
|
@thecrypticace Gotcha, yeah, I mean it's nice not to have to maintain a hardcoded list in a separate package for sure. I wonder if there's something we can do now that we maintain a list of allowed namespaces. Remember the place where we look up things like |
This adds an API that lets us provide
@themevariable completions from within core. The old list was hardcoded in IntelliSense but since the names for some of these changed recently we need a way to control this from within Tailwind CSS itself.IntelliSense PR: tailwindlabs/tailwindcss-intellisense#1104
Do we think this is worth a changelog entry? Kinda thinking not but idk