(n)vim implementation plugin for opening selected content in https://ray.so.
Add the following line to your .vimrc
Plugin 'sudoerwx/vim-ray-so-beautiful'
Then run the following in Vim:
:source %
:PluginInstall
Select some text in visual mode and run this command:
:Ray
You can also map it to something and use it after selection:
vnoremap <F5> :Ray<CR>
idk why you would need that:
let g:ray_base_url = 'http://localhost:3000'
Plugin will try it's best to use your default browser. If it fails, or you want to customize it, provide browser executable through this option to your vimrc. Example for google-chrome:
let g:ray_browser = 'google-chrome'
You can set the query string that will be passed to https://ray.so. Example for setting font and line number:
let g:ray_options =
\ {
\ 'theme' : 'midnight',
\ 'background' : 'true',
\ 'darkMode' : 'true',
\ 'padding' : '64',
\ 'language' : 'auto'
\ }