mirror of
https://github.com/morten-olsen/bob-the-algorithm.git
synced 2026-02-08 00:46:25 +01:00
monorepo
This commit is contained in:
26
packages/app/webpack.config.js
Normal file
26
packages/app/webpack.config.js
Normal file
@@ -0,0 +1,26 @@
|
||||
const path = require("path");
|
||||
const createExpoWebpackConfigAsync = require("@expo/webpack-config");
|
||||
const ReactRefreshWebpackPlugin = require("@pmmmwh/react-refresh-webpack-plugin");
|
||||
|
||||
module.exports = async function (env, argv) {
|
||||
const config = await createExpoWebpackConfigAsync(env, argv);
|
||||
|
||||
// Use the React refresh plugin in development mode
|
||||
if (env.mode === "development") {
|
||||
config.plugins.push(
|
||||
new ReactRefreshWebpackPlugin({
|
||||
forceEnable: true,
|
||||
})
|
||||
);
|
||||
}
|
||||
|
||||
config.module.rules.push({
|
||||
test: /\.tsx?$/,
|
||||
loader: require.resolve("babel-loader"),
|
||||
include: [
|
||||
/@morten-olsen\/ui/,
|
||||
],
|
||||
});
|
||||
|
||||
return config;
|
||||
};
|
||||
Reference in New Issue
Block a user