mirror of
https://github.com/urbit/developers.urbit.org.git
synced 2024-10-26 15:49:50 +03:00
27 lines
684 B
JavaScript
27 lines
684 B
JavaScript
module.exports = {
|
|
reactStrictMode: false,
|
|
// target: 'serverless',
|
|
webpack: (config, { isServer }) => {
|
|
// Fixes npm packages that depend on `fs` module
|
|
if (!isServer) {
|
|
config.resolve.fallback = {
|
|
fs: false,
|
|
path: "path-browserify",
|
|
events: false,
|
|
};
|
|
}
|
|
if (isServer) {
|
|
config.externals.push("_http_common");
|
|
}
|
|
config.resolve.alias.stream = "stream-browserify";
|
|
config.resolve.alias.zlib = "browserify-zlib";
|
|
// config.externals = {
|
|
// ...config.externals,
|
|
// canvas: "util",
|
|
// bufferutil: "bufferutil",
|
|
// "utf-8-validate": "utf-8-validate"
|
|
// }
|
|
return config;
|
|
},
|
|
};
|