this post was submitted on 27 Jun 2023
3 points (100.0% liked)

Neovim

1726 readers
1 users here now

Neovim is a modal text editor forked off of Vim in 2014. Being modal means that you do not simply type text on screen, but the behavior and functionality of the editor changes entirely depending on the mode.

The most common and most used mode, the "normal mode" for Neovim is to essentially turn your keyboard in to hotkeys with which you can navigate and manipulate text. Several modes exist, but two other most common ones are "insert mode" where you type in text directly as if it was a traditional text editor, and "visual mode" where you select text.

Neovim seeks to enable further community participation in its development and to make drastic changes without turning it in to something that is "not Vim". Neovim also seeks to enable embedding the editor within GUI applications.

The Neovim logo by Jason Long is licensed under the Creative Commons Attribution 3.0 Unported License.

founded 3 years ago
MODERATORS
 

Hello !

In my day to day work I often have to write small snippets to illustrate ticket tech strategy.

I was wondering if you guys knew a cool way to have quick scratchpad where I could manipulate the snippet, format it, and have minimal syntax coloration.

This is usually handled by LSP, but sometimes having a full lsp running is not practical, with all the overhead of typescript config for example.

Main formats are JSON, typescript and soon Rust.

Cheers

you are viewing a single comment's thread
view the rest of the comments
[–] aistina@lemmy.world 1 points 1 year ago (1 children)

I think Neoformat lets you format a buffer without saving it, without the need for an LSP. So you could:

:enew 
:set syntax=json
(Write some code)
:Neoformat <formatter-name>

https://github.com/sbdchd/neoformat

[–] Paria_Stark@lemmy.world 1 points 1 year ago (1 children)

Wow it actually looks like exactly what I am looking for. Thanks !

[–] aistina@lemmy.world 2 points 1 year ago

You’re welcome! Glad I could help.