mirror of https://github.com/status-im/metro.git
[React Native][Packager] allow --assetRoots to be relative paths
This commit is contained in:
parent
bc1f94b7b2
commit
fca872fac2
|
@ -86,7 +86,9 @@ if (options.root) {
|
|||
|
||||
if (options.assetRoots) {
|
||||
if (!Array.isArray(options.assetRoots)) {
|
||||
options.assetRoots = options.assetRoots.split(',');
|
||||
options.assetRoots = options.assetRoots.split(',').map(function (dir) {
|
||||
return path.resolve(process.cwd(), dir);
|
||||
});
|
||||
}
|
||||
} else {
|
||||
if (__dirname.match(/node_modules\/react-native\/packager$/)) {
|
||||
|
|
Loading…
Reference in New Issue