Skip to content

Commit 6906e6c

Browse files
author
Gitlab-CI
committed
fix(createConfig): fixed default Wrapper and Layout path using __dirname instead of base for their import
1 parent abd6c8d commit 6906e6c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/createConfig.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -199,8 +199,8 @@ export function createConfig(config = {}, options = {}) {
199199
}
200200

201201
// Local Layout and Wrapper in case no selection
202-
const defaultStyleGuidePath = join(base, 'src/Layout');
203-
const defaultWrapperPath = join(base, 'src/Wrapper');
202+
const defaultStyleGuidePath = existsSync(join(__dirname, 'src/Layout')) ? join(__dirname, 'src/Layout') : join(__dirname, 'lib/Layout');
203+
const defaultWrapperPath = existsSync(join(__dirname, 'src/Wrapper')) ? join(__dirname, 'src/Wrapper') : join(__dirname, 'lib/Wrapper');
204204

205205
// External layout selection
206206
const {

0 commit comments

Comments
 (0)