GithubHelp home page GithubHelp logo

Comments (7)

clinyong avatar clinyong commented on August 16, 2024

Could you supply a reproduced demo?

from vscode-css-modules.

owlmafia avatar owlmafia commented on August 16, 2024

@clinyong actually, I just noticed that the problem is specific to ids (when using the id attribute instead of class). Is that a known limitation?

Also, when using classes, is there a way to prevent this selection?

Screen Shot 2022-11-24 at 16 30 44

These issues can be reproduced with a nextjs starter project:

npx create-next-app@latest nextjs-blog --use-npm --example "https://github.com/vercel/next-learn/tree/master/basics/learn-starter"

from vscode-css-modules.

clinyong avatar clinyong commented on August 16, 2024

Yes, the id attribute is not supported. We can't prevent the selection because there isn't an api for extension to do this.

from vscode-css-modules.

owlmafia avatar owlmafia commented on August 16, 2024

Would a feature request for the id make sense? And about the api, would it make sense to open an issue on the vscode repo maybe (I could do it)?

Edit: actually, id is not so important to me. I can easily replace them with classes.

from vscode-css-modules.

karlhorky avatar karlhorky commented on August 16, 2024

I think the "duplicate definitions in Go to Definition" issue is documented over here:

As I mentioned in my last comments, someone could open an issue in the microsoft/vscode or microsoft/TypeScript repos to present the use case clearly and ask for some way for an extension (or user configuration) to be able to disable useless definition entries in Go to Definition.

from vscode-css-modules.

karlhorky avatar karlhorky commented on August 16, 2024

For Next.js itself, you can also consider modifying the node_modules/next/types/global.d.ts file containing these types, as I mentioned in #63 (comment)

You could modify it permanently in your project using something like patch-package.

from vscode-css-modules.

iChenLei avatar iChenLei commented on August 16, 2024

@clinyong actually, I just noticed that the problem is specific to ids (when using the id attribute instead of class). Is that a known limitation?

Also, when using classes, is there a way to prevent this selection?

Screen Shot 2022-11-24 at 16 30 44

These issues can be reproduced with a nextjs starter project:

npx create-next-app@latest nextjs-blog --use-npm --example "https://github.com/vercel/next-learn/tree/master/basics/learn-starter"

Duplicate #63

from vscode-css-modules.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.