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

Implement some language features #76

Merged
merged 7 commits into from
Feb 2, 2025
Merged

Conversation

mizdra
Copy link
Owner

@mizdra mizdra commented Feb 2, 2025

Overview

2025-02-02.18.29.36.mov

Features

Create CSS Module file for current file

If there is no CSS Module file corresponding to xxx.tsx, create one.

2025-02-02.19.07.06.mov
Complete `className={...}` instead of `className="..."`

In projects where CSS Modules are used, the element is styled with className={styles.xxx}. However, when you type className, className="..." is completed. This is annoying to the user.

So, instead of className="..." instead of className={...} instead of className="...".

2025-02-02.19.07.27.mov
Prioritize the `styles' import for the current component file

When you request styles completion, the CSS Module file styles will be suggested. If there are many CSS Module files in the project, more items will be suggested. This can be confusing to the user.

So I have made it so that the styles of the CSS Module file corresponding to the current file is shown first.

image
Add missing CSS rule

If you are trying to use a class name that is not defined, you can add it with Quick Fixes.

2025-02-02.19.24.36.mov

@mizdra mizdra force-pushed the implement-language-features-2 branch 2 times, most recently from 4097f2b to 1414042 Compare February 2, 2025 09:49
@mizdra mizdra force-pushed the implement-language-features-2 branch from 715e28c to 06f9096 Compare February 2, 2025 10:02
@mizdra mizdra marked this pull request as ready for review February 2, 2025 10:03
@mizdra mizdra mentioned this pull request Jan 28, 2025
13 tasks
@mizdra mizdra merged commit 73fa52a into main Feb 2, 2025
6 checks passed
@mizdra mizdra deleted the implement-language-features-2 branch February 2, 2025 10:31
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.

1 participant