How do I convert R code to HTML?

Can you be more precise on this ? what do you want to achieve ?
To expose data between program, making an API is one solution and plumber :package: is great for that !

EDIT: For reference, there is another thread about that. How to save JSON Data into R Markdown