Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Conversation

@dyhagho
Copy link
Contributor

@dyhagho dyhagho commented Nov 18, 2023

Context

When importing partials (e.g "_mixins.scss"), it's unnecessary to explicitly include the underscore (_). Sass inherently understands and imports files with or without the underscore. Therefore, @import "mixins.scss" is a valid way to import the partial.

Why has this change been made?

Navigating to a partial file using Command + Click or Control + Click without specifying the underscore was causing the language server to be unable to find the path.

Changes

  • Update toPathVariations function to consider partial files when the underscore has been omitted.
  • Add a new test case to ensure accurate resolution when the underscore is omitted when import partial files.

Before

before

After

after

@dyhagho
Copy link
Contributor Author

dyhagho commented Nov 18, 2023

@microsoft-github-policy-service agree

@aeschli aeschli added this to the November 2023 milestone Nov 27, 2023
@aeschli aeschli merged commit f86d093 into microsoft:main Nov 27, 2023
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.

3 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.