mirror of
https://github.com/zhigang1992/create-react-app.git
synced 2026-04-28 17:35:42 +08:00
Work around weird inferred name in Chrome
This commit is contained in:
@@ -142,7 +142,10 @@ function createFrame(
|
||||
// Chrome has a bug with inferring function.name:
|
||||
// https://github.com/facebookincubator/create-react-app/issues/2097
|
||||
// Let's ignore a meaningless name we get for top-level modules.
|
||||
if (functionName === 'Object.friendlySyntaxErrorLabel') {
|
||||
if (
|
||||
functionName === 'Object.friendlySyntaxErrorLabel' ||
|
||||
functionName === 'Object.exports.__esModule'
|
||||
) {
|
||||
functionName = '(anonymous function)';
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user