-
Notifications
You must be signed in to change notification settings - Fork 0
/
metro.config.js
28 lines (25 loc) · 878 Bytes
/
metro.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
// metro.config.js
//
// with multiple workarounds for this issue with symlinks:
// https://github.com/facebook/metro/issues/1
//
// with thanks to @johnryan (<https://github.com/johnryan>)
// for the pointers to multiple workaround solutions here:
// https://github.com/facebook/metro/issues/1#issuecomment-541642857
//
// see also this discussion:
// https://github.com/brodybits/create-react-native-module/issues/232
const path = require('path')
module.exports = {
// workaround for an issue with symlinks encountered starting with
// [email protected] / React Native 0.61
// (not needed with React Native 0.60 / [email protected])
resolver: {
extraNodeModules: new Proxy(
{},
{ get: (_, name) => path.resolve('.', 'node_modules', name) }
)
},
// quick workaround for another issue with symlinks
watchFolders: [path.resolve('.'), path.resolve('..')]
}