Coder Social home page Coder Social logo

Comments (3)

DavidAnson avatar DavidAnson commented on June 2, 2024

This MAY already work today for ESM modules - but if so, it will NOT work within VS Code because Electron does not load ESM modules (yet). You could try this via CLI2 directly - my thinking is that the existing fallback of require to import may/should "just work" for this.

from vscode-markdownlint.

skwde avatar skwde commented on June 2, 2024

I have no idea what you are talking about.

Obviously it doesn't work, but it would be nice if it does. It would no longer require to have a node install just for an additional lint rule.

from vscode-markdownlint.

DavidAnson avatar DavidAnson commented on June 2, 2024

If you're talking about markdownlint-cli2 automatically running npm or yarn to install custom rule packages, that's outside the scope of what I think this tool should do. If you're suggesting markdownlint-cli2 should try to download all the the implicit/explicit scripts and (sub-)dependencies of an arbitrary JavaScript file as shown above, that's even further out of scope in my mind.

The way something like this could work is via ESM modules... however trying that myself produces the following error from Node 20, so I don't think this is practical yet:

    Error [ERR_UNSUPPORTED_ESM_URL_SCHEME]: Only URLs with a scheme in: file, data, and node are supported by the default ESM loader. Received protocol 'http:'

from vscode-markdownlint.

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.