mirror of
https://github.com/hanzoai/prettier.git
synced 2026-09-24 17:02:04 +00:00
df7194b385
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: fisker <[email protected]>
12 lines
285 B
JavaScript
12 lines
285 B
JavaScript
export default function esbuildPluginStripNodeProtocol() {
|
|
return {
|
|
name: "strip-node-protocol",
|
|
setup(build) {
|
|
build.onResolve(
|
|
{ filter: /^node:/, namespace: "file" },
|
|
({ path, kind }) => build.resolve(path.slice(5), { kind }),
|
|
);
|
|
},
|
|
};
|
|
}
|