TransformIgnose忽略所有反应本机节点模块?

时间:2019-01-11 15:35:16

标签: reactjs react-native jestjs babel-jest

我有这么长的反应本机节点模块列表可以忽略。我知道我需要忽略所有这些。有没有办法将下面的transformIgnorePatterns数组重构为更干净的东西?

"transformIgnorePatterns": ["node_modules/(?!(react-native|react-native-linear-gradient|react-native-svg|react-native-config|react-native-version-number|react-native-permissions|react-native-iphone-x-helper|react-navigation|react-native-htmlview|react-native-tag-input|react-native-fade-in-image|react-native-calendars|react-native-scrollable-tab-view|react-native-store-review)/)"],

我已经尝试了以下方法,但是根本没有用。

"transformIgnorePatterns": ["node_modules/react-(?!(native|native-*))]"

谢谢

0 个答案:

没有答案