Skip to content

yoshimi-I/nvim-browser

Repository files navigation

nvim-browser

nvim-browser is an experimental browser runtime for Neovim.

The goal is to keep browsing, Markdown preview, and image preview inside the terminal/Neovim workflow instead of jumping to an external browser tab. The first target terminal is Ghostty, using terminal graphics as the future display surface.

Status

This repository is an early MVP scaffold. Today it includes:

  • Rust backend binary: nvbrowser
  • target classification for URLs, Markdown, HTML, and images
  • Markdown-to-HTML rendering
  • image output through Kitty graphics protocol
  • Neovim commands for opening and inspecting targets
  • initial OSS packaging and CI

Planned next steps:

  • Chromium/CDP renderer backend
  • Chromium/CDP page screenshots displayed through Kitty graphics protocol
  • tile-based page screenshots inside a Neovim preview split
  • scroll/input bridge from Neovim to the browser session
  • image, SVG, PDF, Mermaid, and KaTeX preview through the same browser runtime

Architecture

Ghostty
└─ Neovim
   ├─ Lua plugin
   │  ├─ commands.lua
   │  ├─ backend.lua
   │  └─ terminal.lua
   └─ Rust backend
      ├─ nvbrowser-core
      │  ├─ target
      │  ├─ markdown
      │  └─ terminal/kitty
      └─ nvbrowser-cli

See docs/architecture.md for module boundaries.

Requirements

  • Neovim 0.10+
  • Rust stable
  • Ghostty for the intended terminal graphics experience

Development

Build the backend:

cargo build

Run tests:

cargo test

Try the backend:

cargo run -p nvbrowser -- inspect https://example.com
cargo run -p nvbrowser -- render-md README.md
cargo run -p nvbrowser -- show-image path/to/image.png

Try the plugin from this checkout:

nvim --cmd 'set rtp+=.'

Then run:

:NBrowserInspect https://example.com
:NBrowserPreview

License

MIT

About

Neovim-native browser runtime for Ghostty-first browsing, Markdown, and image preview

Topics

Resources

License

Contributing

Stars

2 stars

Watchers

0 watching

Forks

Packages

 
 
 

Contributors