Files
react-native/metro.config.js
T
Rob Hogan 7923804c28 Use newer metro language: blacklistRE -> blockList (#30342)
Summary:
An [update to `metro`](https://github.com/facebook/metro/commit/94c0b541b4bfa17aee4efa0f1969565522ce830d#diff-1a3c1a959bb8c4e2e9743c03cb7a6d0c56648ffcfe129a11b9090bfc139622dd) which landed in metro 0.60 (RN 0.64+) deprecates the config `blacklistRE`, renaming it to `blockList`. Although the former is still supported it now generates a deprecation warning.

## Changelog

[General] [Fixed] - Update metro config language to `blockList`

Pull Request resolved: https://github.com/facebook/react-native/pull/30342

Test Plan: Confirm that the config is still respected (`/buck-out/` should be excluded), and that no deprecation warning is issued.

Reviewed By: lunaleaps

Differential Revision: D31380163

Pulled By: motiz88

fbshipit-source-id: f64cff30690f0252fafd4eac254a8c2278c4ac2f
2021-10-05 02:26:26 -07:00

31 lines
672 B
JavaScript

/**
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
* @flow
* @format
*/
'use strict';
const getPolyfills = require('./rn-get-polyfills');
/**
* This cli config is needed for development purposes, e.g. for running
* integration tests during local development or on CI services.
*/
module.exports = {
resolver: {
// $FlowFixMe[signature-verification-failure] Can't infer RegExp type.
blockList: /buck-out/,
extraNodeModules: {
'react-native': __dirname,
},
},
serializer: {
getPolyfills,
},
};