hasit / vscode-plush

Plush syntax support for VSCode
MIT License
1 stars 2 forks source link

vscode-plush

plush version plush installs plush ratings

Plush syntax support for VSCode. Currently supports snippets. Eventually, will contain support for syntax highlighting and complete autoformatting of Plush tags in HTML files.

Snippets and Bindings

Snippet Prefix Output
expression tag ple <% expression %>
print tag plp <%= expression %>
if block plif <%= if (condition) { %> ... <% } %>
if else block plie <%= if (condition) { %> ... <% } else { %> ... <% } %>
map plm <% let name = {key: value} %>
array pla <% let name = [values] %>
for plf <%= for (key, value) in expression { %><%= key %> <%= value %><% } %>
javascript Tag pljs <%= javascriptTag("filename.js") %>
stylesheet Tag plst <%= stylesheetTag("filename.css") %>
partial plpa <%= partial("partials/filename.html") %>
form for plfm <%= form_for(model, {action:"path()", method: "POST"}) { %><%= f.InputTag("FieldName", {}) %><% } %>

References

Plush