mirror of
https://github.com/facebook/react-native.git
synced 2026-11-18 20:19:07 +00:00
Make INTERNAL_CALLSITES_REGEX work with Windows paths (#44469)
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/44469 Changelog: [General][Fixed] LogBox and Chrome DevTools stack frame collapsing patterns are now compatible with Windows file paths. Reviewed By: GijsWeterings Differential Revision: D57091214 fbshipit-source-id: f62d9fe7f3d4f91ed8ea07521b174989c2dd1c81
This commit is contained in:
1 parent
2d8c6f591c
commit
8d0046a5e1
1 file changed
+4
-1
@@ -35,7 +35,10 @@ const INTERNAL_CALLSITES_REGEX = new RegExp(
|
||||
'/node_modules/react-refresh/.+\\.js$',
|
||||
'/node_modules/scheduler/.+\\.js$',
|
||||
'^\\[native code\\]$',
|
||||
].join('|'),
|
||||
]
|
||||
// Make patterns work with both Windows and POSIX paths.
|
||||
.map(pathPattern => pathPattern.replaceAll('/', '[/\\\\]'))
|
||||
.join('|'),
|
||||
);
|
||||
|
||||
export {mergeConfig} from 'metro-config';
|
||||
|
||||
Reference in new issue
Block a user