Coder Social home page Coder Social logo

Comments (6)

bathos avatar bathos commented on June 1, 2024 1

It seems reasonable to me to make the syntax: prefix optional. If that aligns with how others are doing this, it’s definitely a lot simpler than adding a runtime thingie for generating (and then managing?) custom definitions.

from ecmascript-sublime.

bathos avatar bathos commented on June 1, 2024

AFAIK, doing this would require generating new versions of the syntax definition dynamically in response to settings changes, implying a runtime component to this plugin that doesn’t currently exist. My guess is that it would be possible. Maybe there’s some prior art out there for this?

@blake-regalia is that correct, or do you know of other mechanisms by which user variables could be used in sublime syntax definitions?

from ecmascript-sublime.

blake-regalia avatar blake-regalia commented on June 1, 2024

Not feasible. Syntax definitions currently have to be static in Sublime Text other than the way @bathos describes.

@joshfester i'd be curious to know how do the other editors/plugins use such directives? Keep in mind that we also support highlighting triggered by a few template tags such as html and css (which we should probably document).

from ecmascript-sublime.

joshfester avatar joshfester commented on June 1, 2024

@blake-regalia it seems like most of them use /* {SYNTAX_NAME} */. However, I believe template tags would also be a great solution. I was not aware there was support for that!

from ecmascript-sublime.

joshfester avatar joshfester commented on June 1, 2024

That would be perfect!

from ecmascript-sublime.

blake-regalia avatar blake-regalia commented on June 1, 2024

@joshfester see 2.4.0.

I'm going to close this issue for now but I am still interested in dynamic or user-generated nested syntax capabilities. Feel free to open a new issue for that if you'd like.

from ecmascript-sublime.

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.