We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hi,
I have an existing config-overrides.js file that was created after following the following tutorial: code-sharing-between-ios-android--web-using-react-native-web
config-overrides.js
Which results with the following file content:
const fs = require('fs'); const path = require('path'); const webpack = require('webpack'); const appDirectory = fs.realpathSync(process.cwd()); const resolveApp = relativePath => path.resolve(appDirectory, relativePath); // our packages that will now be included in the CRA build step const appIncludes = [ resolveApp('src'), resolveApp('../components/src'), ]; module.exports = function override(config, env) { // allow importing from outside of src folder config.resolve.plugins = config.resolve.plugins.filter( plugin => plugin.constructor.name !== 'ModuleScopePlugin' ); config.module.rules[0].include = appIncludes; config.module.rules[1] = null; config.module.rules[2].oneOf[1].include = appIncludes; config.module.rules[2].oneOf[1].options.plugins = [ require.resolve('babel-plugin-react-native-web'), ].concat(config.module.rules[2].oneOf[1].options.plugins); config.module.rules = config.module.rules.filter(Boolean); config.plugins.push( new webpack.DefinePlugin({__DEV__: env !== 'production'}) ); return config };
How can I merge this with the required override modifications you provided?
override
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Hi,
I have an existing
config-overrides.js
file that was created after following the following tutorial: code-sharing-between-ios-android--web-using-react-native-webWhich results with the following file content:
How can I merge this with the required
override
modifications you provided?The text was updated successfully, but these errors were encountered: