N
N
nurise2015-08-21 19:27:49
npm
nurise, 2015-08-21 19:27:49

Is there any npm package to convert code to image?

you need to convert the source code to a highlight image on the fly, like in instacode.es, only as an npm package, or some other open source solution

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dexmaster, 2015-08-21
@Dexmaster

Everything you need is in PhantomJS , you just need to connect the css of the highlight you need to the template.
A very simple example is in the " examples/rasterize.js " subfolder.
phantomjs.org/screen-capture.html
Sample project.
https://github.com/nathanpeck/webkit-html-to-image...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question