Answers for "react 360 Invalid regular expression: /(node_modules[\\\]react[\\\]dist[\\\].*|website\\node_modules\\.*|heapCapture\\bundle\.js|.*\\__tests__\\.*)$/: Unterminated character class"

2

Invalid regular expression: /(.*\\__fixtures__\\.*|node_modules[\\\]react[\\\]dist[\\\].*|website\\node_modules\\.*|heapCapture\\bundle\.js|.*\\__tests__\\.*)$/: Unterminated character class

To fix the Invalid Regular Expressing while running 

react-native start
Go to \node_modules\metro-config\src\defaults\blacklist.js
if metro-config not found
then, go to \node_modules\metro\src\blacklist.js

Replace the SharedBlacklist with the following

var sharedBlacklist = [
    /node_modules[\/\\]react[\/\\]dist[\/\\].*/,
    /website\/node_modules\/.*/,
    /heapCapture\/bundle\.js/,
    /.*\/__tests__\/.*/
];
Posted by: Guest on February-04-2021

Code answers related to "react 360 Invalid regular expression: /(node_modules[\\\]react[\\\]dist[\\\].*|website\\node_modules\\.*|heapCapture\\bundle\.js|.*\\__tests__\\.*)$/: Unterminated character class"

Code answers related to "Javascript"

Browse Popular Code Answers by Language