nvim-react (:construction: WIP)

January 25, 2023 ยท View on GitHub

Reactive UI rendering framework for Neovim

https://user-images.githubusercontent.com/18459807/212144062-28756d23-1c42-4171-9cd8-a49a866ac9e8.mp4

Features

  • Functional components
  • Signals (something like useState in ReactJS)
  • Complex data stores (:construction: WIP)
  • Lifecycle callbacks
  • Keymap events
  • Highlighting

Development

Open the project

nvim -c "luafile dev/init.lua"

Try <leader><leader>w keymap

Run tests

:warning: Running tests requires plenary.nvim to be checked out in the parent directory of this repository :warning:

You can then run:

nvim \
--headless \
--noplugin \
-u tests/minimal.vim \
-c "PlenaryBustedDirectory tests/ {minimal_init = 'tests/minimal.vim'}"

Or if you want to run a single test file:

nvim \
--headless \
--noplugin \
-u tests/minimal.vim \
-c "PlenaryBustedDirectory tests/path_to_file.lua {minimal_init = 'tests/minimal.vim'}"