robin/laufey
git clone https://git.robinwobin.dev/robin/laufey
59eadebe33
master
1if vim . g . loaded_2html_plugin ~= nil then 2return 3end 4vim . g . loaded_2html_plugin =true 5 6vim . api . nvim_create_user_command ( 'TOhtml' , function ( args ) 7local outfile =args . args ~= '' and args . args or vim . fn . tempname () .. '.html' 8local html =require ( 'tohtml' ). tohtml ( 0 , { range ={ args . line1 , args . line2 } } ) 9vim . fn . writefile ( html , outfile ) 10vim . cmd . split ( outfile ) 11vim . bo . filetype ='html' 12end , { bar =true , nargs ='?' , range ='%' , complete ='file' } )