Add support for node: protocol
Author: kptdobeCreated Sep 17, 2021Updated Jun 4, 2024
The node: protocol (https://github.com/nodejs/node/issues/38343) does not seem to be supported or I do not know how to "make it happen".
main.js
import { toMdast } from 'hast-util-to-mdast';Install:
npm install --save-dev esmify browserify
npm install hast-util-to-mdastRun:
npx browserify -p esmify main.js -o bundle.jsOutput:
Error: Can't walk dependency graph: Cannot find module 'node:url' from 'node_modules/hast-util-to-mdast/lib/util/resolve.js'The library uses the node: protocole: https://github.com/syntax-tree/hast-util-to-mdast/blob/main/lib/util/resolve.js#L5
Any hint to resolve this would be really appreciated! Thanks
Source: browserify/browserify