You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You might want to create a custom function that writes the file, runs the cli version of this tool(asuming you have one installed) and reloads the file.
Here is my crappy implementation:
if (&ft=='stylus')
functionStylusSupremacy()
:w"saves the file"run the actual commandexecute"!(~/.yarn/bin/stylus-supremacy format " . expand('%') . " --replace --options ~/.stylus.json)"
:e"reloads the fileendfunctioncommand! StylusSupremacy callStylusSupremacy()
map<leader>p :StylusSupremacy<CR>endif
You might want to update the path to executable and path to config file, but other than that it should do the trick for you. The keybind is \p assuming you haven't remapped your leader key.
P.S. You should probably put your configs into separate files for each filetype instead of doing if (&ft=='.stylus')
how can i use in vim?
The text was updated successfully, but these errors were encountered: