Created by: tuxflo
neovim-remote (nvr
) is a tool to open files from an external command to an existing neovim session. If the neovim session which is used for the CRA project is started with NVIM_LISTEN_ADDRESS=/tmp/nvimsocket nvim
, nvr
can be used from the CRA error page to jump directly to the file/line if an error occurs.
To use it one only has to set the environment var:
REACT_EDITOR=nvr
Steps to test:
- install
nvr
- start neovim session wit
NVIM_LISTEN_ADDRESS=/tmp/nvimsocket nvim
- set REACT_EDITOR=nvr
- open development project (
yarn start
) in Browser and produce error - click on error message
Result: the file containing the error is opened in the existing neovim session. If the file is already open in a buffer, jump to the line containing the error.