-
-
Notifications
You must be signed in to change notification settings - Fork 30
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
How to write a snippet for javascript? #168
Comments
It's better to use native Sublime Text snippets in your case. If you still want to create Emmet snippet, you should wrap custom text with Emmet snippets are actually aliases for Emmet abbreviations, you define output structure with it |
{ |
Not sure what you mean. Emmet doesn't work in JS by default, only in JSX with prefixed mode: https://github.com/emmetio/sublime-text-plugin#jsx-support |
OK, thanks. |
For example, how to do this:
"cl": "console.log(' $ ');"
$ - cursor
Emmet.subling-settings:
{
"config": {
"html": {
"snippets": {
"test": ".gg", // working
"c": "{Hello}", // working
}
},
"css" : {
"snippets" : {
"pss" : "padding: 1px 2px 1px 2px;" // working
}
},
"markup" : {
"snippets" : {
"cl": "console.log();" // does not work
}
}
}
}
The text was updated successfully, but these errors were encountered: