Browser version in ./dist/?
dereks opened this issue · comments
I am using markdown-it in the browser and would like to use this plugin.
The documentation shows using require()
, which doesn't work in my browser.
[...].use(require('markdown-it-replace-link'))
I am new to node.js. Based on my reading, I think this code still needs a Makefile that runs browserify
, and puts the browser-friendly version into ./dist/. Is that correct?
I've looked at other browser-friendly markdown-it plugins and that seems to be what they have done. They export a variable, for example, window.markdownitLinkifyImages
, that can be used in the browser instead of require('markdown-it-replace-link')
.
Would it be possible to provide a browser-friendly version? If not, I would be happy to contribute a Pull Request, if this is the correct approach.
Thanks!
Pull Request submitted...
Hello @dereks Thank you for the PR, I invited you to become a collaborator.
And published it as markdown-it-replace-link@1.0.1
@dereks I saw that you accepted the invitation. Please ping me with your npm username if you want/need npm rights.