Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

adding web5 services #2

Merged
merged 2 commits into from
May 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
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
25 changes: 22 additions & 3 deletions craco.config.js
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;
},
},
};
18 changes: 8 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
"private": true,
"homepage": "https://andorsk.github.io/web5-calendly",
"dependencies": {
"@craco/craco": "^7.1.0",
"@emotion/react": "^11.11.4",
"@emotion/styled": "^11.11.5",
"@mui/icons-material": "^5.15.18",
Expand All @@ -19,6 +18,8 @@
"@types/react-dom": "^18.3.0",
"@types/react-redux": "^7.1.33",
"@types/react-router-dom": "^5.3.3",
"@web5/api": "^0.9.3",
"browser": "link:@web5/api/browser",
"date-fns": "^3.6.0",
"gapi-script": "^1.2.0",
"react": "^18.3.1",
Expand All @@ -38,25 +39,22 @@
"eject": "craco eject"
},
"eslintConfig": {
"extends": [
"react-app",
"react-app/jest"
]
"extends": ["react-app", "react-app/jest"]
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"production": [">0.2%", "not dead", "not op_mini all"],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
},
"devDependencies": {
"@craco/craco": "^7.1.0",
"@testing-library/jest-dom": "^5.17.0",
"crypto-browserify": "^3.12.0",
"process": "^0.11.10",
"stream-browserify": "^3.0.0",
"tailwindcss": "^3.4.3"
}
}
Loading
Loading