
Product
Introducing Webhook Events for Alert Changes
Add real-time Socket webhook events to your workflows to automatically receive software supply chain alert changes in real time.
rehype-parse-isomorphic
Advanced tools
A module that exports rehype-parse for Node.js and rehype-dom-parse for the browser.
rehype-parse for Node.js and rehype-dom-parse for the browser.
$ npm i rehype-parse-isomorphic
Use just like
rehype-parse
and
rehype-dom-parse.
[!WARNING]
The two libraries do not have exactly the same options. Make sure you account for the differences when the library is used in Node.js vs the browser.
It's better to use rehype-dom-parse than rehype-parse in the browser because
the former has a significantly smaller bundle size
(~8 kB vs
~63 kB).
Typically it's possible to just import rehype-parse in Node.js and
rehype-dom-parse in the browser, but not always. Sometimes you want to parse
HTML in code that can be used in either the browser or Node.js (i.e. in
isomorphic code). Which
library would you import in that code?
Without this module you'd be forced to import the lowest common denominator, the
library that works in both Node.js and the browser, which would be
rehype-parse. And now your browser JavaScript bundle is ~55 kB bigger than it
should have been! With this module, you use the right library in each
environment.
Stars are always welcome!
For bugs and feature requests, please create an issue.
MIT
© Tomer Aberbach
Apache 2.0 ©
Google
FAQs
A module that exports rehype-parse for Node.js and rehype-dom-parse for the browser.
The npm package rehype-parse-isomorphic receives a total of 0 weekly downloads. As such, rehype-parse-isomorphic popularity was classified as not popular.
We found that rehype-parse-isomorphic demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Product
Add real-time Socket webhook events to your workflows to automatically receive software supply chain alert changes in real time.

Security News
ENISA has become a CVE Program Root, giving the EU a central authority for coordinating vulnerability reporting, disclosure, and cross-border response.

Product
Socket now scans OpenVSX extensions, giving teams early detection of risky behaviors, hidden capabilities, and supply chain threats in developer tools.