-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2 from andorsk/ask/web5
adding web5 services
- Loading branch information
Showing
13 changed files
with
1,478 additions
and
1,187 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,28 @@ | ||
const path = require("path"); | ||
const webpack = require("webpack"); | ||
|
||
module.exports = { | ||
webpack: { | ||
alias: { | ||
"@": path.resolve(__dirname, "src/"), | ||
configure: (webpackConfig) => { | ||
webpackConfig.resolve.fallback = { | ||
...webpackConfig.resolve.fallback, | ||
stream: require.resolve("stream-browserify"), | ||
crypto: require.resolve("crypto-browserify"), | ||
process: require.resolve("process/browser"), | ||
}; | ||
|
||
webpackConfig.plugins.push( | ||
new webpack.ProvidePlugin({ | ||
process: "process/browser.js", | ||
}), | ||
new webpack.ProvidePlugin({ | ||
crypto: "crypto-browserify", | ||
}), | ||
new webpack.NormalModuleReplacementPlugin(/node:crypto/, (resource) => { | ||
resource.request = resource.request.replace(/^node:/, ""); | ||
}), | ||
); | ||
|
||
return webpackConfig; | ||
}, | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.