Skip to content

Commit

Permalink
fix(browser-bundle): Correctly configure built-ins in browserify
Browse files Browse the repository at this point in the history
The builtins were wrongly passed in the root configuration object. They
should be set in the `builtins` property.

Close eclipse-thingweb#785
Signed-off-by: reluc <relu.cri@gmail.com>
  • Loading branch information
relu91 committed Jul 27, 2022
1 parent d5369d1 commit 9894395
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions packages/browser-bundle/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,15 @@ const _stream_writable = require.resolve("readable-stream4/lib/_stream_writable"
const fs = require("fs");

const builder = browserify({
...builtIns,
stream,
_stream_duplex,
_stream_passthrough,
_stream_readable,
_stream_transform,
_stream_writable,
builtins: {
...builtIns,
stream,
_stream_duplex,
_stream_passthrough,
_stream_readable,
_stream_transform,
_stream_writable,
},
});

builder.add("./index.js");
Expand Down

0 comments on commit 9894395

Please sign in to comment.