Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ const serverWebpackConfig = require('./serverWebpackConfig');
const webpackConfig = (envSpecific) => {
const clientConfig = clientWebpackConfig();
const serverConfig = serverWebpackConfig();
clientConfig.resolve.fallback = { stream: false };
// Remove the next line if you used "node" target in serverWebpackConfig.js
serverConfig.resolve.fallback = { stream: false };

if (envSpecific) {
envSpecific(clientConfig, serverConfig);
Expand Down
1 change: 0 additions & 1 deletion spec/dummy/config/webpack/alias.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ module.exports = {
resolve: {
alias: {
Assets: resolve(__dirname, '..', '..', 'client', 'app', 'assets'),
stream: 'stream-browserify',
},
},
};
4 changes: 3 additions & 1 deletion spec/dummy/config/webpack/webpackConfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ const serverWebpackConfig = require('./serverWebpackConfig');
const webpackConfig = (envSpecific) => {
const clientConfig = clientWebpackConfig();
const serverConfig = serverWebpackConfig();
clientConfig.resolve.fallback = { stream: require.resolve('stream-browserify') };
clientConfig.resolve.fallback = { stream: false };
// Remove the next line if you used "node" target in serverWebpackConfig.js
serverConfig.resolve.fallback = { stream: false };

if (envSpecific) {
envSpecific(clientConfig, serverConfig);
Expand Down
2 changes: 1 addition & 1 deletion spec/dummy/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@
"format": "cd ../.. && yarn start format",
"test": "yarn run build:test && yarn run lint && rspec",
"build:test": "rm -rf public/webpack/test && yarn build:rescript && RAILS_ENV=test NODE_ENV=test bin/shakapacker",
"build:dev": "rm -rf public/webpack/development && yarn build:rescript && RAILS_ENV=development NODE_ENV=development bin/shakapacker --watch",
"build:dev": "rm -rf public/webpack/development && yarn build:rescript && RAILS_ENV=development NODE_ENV=development bin/shakapacker",
"build:dev:server": "rm -rf public/webpack/development && yarn build:rescript && RAILS_ENV=development NODE_ENV=development bin/shakapacker --watch",
"build:dev:watch": "rescript build -w && RAILS_ENV=development NODE_ENV=development bin/shakapacker --watch",
"build:clean": "yarn build:rescript && rm -rf public/webpack || true",
Expand Down
Loading