Skip to content

Conversation

@manmen-mi
Copy link

@manmen-mi manmen-mi commented Sep 30, 2024

fix #1060

match RegExp HAS_IMPORT with fileMayBeTailwindRelated()


let HAS_IMPORT = /@import\s*('[^']+'|"[^"]+");/
let HAS_IMPORT = /@import\s*['"]/ // from fileMayBeTailwindRelated()

It seemed like the regex only accepted @import '~~~';, so @import '~~~' layer(xxx); did not match.
Therefore, I loosened the regex of HAS_IMPORT a bit so that it would match the other parts.

translated from japanese

@thecrypticace
Copy link
Contributor

oops… lol. Thanks for the PR and the tests 💯

@thecrypticace thecrypticace merged commit 83cccdb into tailwindlabs:main Sep 30, 2024
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.

IntelliSense doesn't initialize project without @import 'tailwindcss'

3 participants