mirror of
https://github.com/zhigang1992/create-react-app.git
synced 2026-04-29 09:55:43 +08:00
Fix absolute paths issue in Jest (#7822)
This commit is contained in:
committed by
Ian Sutherland
parent
ab41c4c5c5
commit
889df8e65b
2
packages/react-scripts/config/modules.js
vendored
2
packages/react-scripts/config/modules.js
vendored
@@ -101,7 +101,7 @@ function getJestAliases(options = {}) {
|
||||
|
||||
if (path.relative(paths.appPath, baseUrlResolved) === '') {
|
||||
return {
|
||||
'src/(.*)$': '<rootDir>/src/$1',
|
||||
'^src/(.*)$': '<rootDir>/src/$1',
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user