We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f2c0358 commit 44e19ffCopy full SHA for 44e19ff
src/index.ts
@@ -289,5 +289,5 @@ function insertComponent(node: any, componentName: string, state: any) {
289
function defaultJudgePage(filePath: string) {
290
// 兼容 windows 路径
291
const formatFilePath = filePath.replace(/\\/g, '/')
292
- return /(package-.+\/)?pages\/.+\/index\.[tj]sx$/.test(formatFilePath)
+ return /(package-.+\/)?pages\/[A-Za-z0-9-]+\/index\.[tj]sx$/.test(formatFilePath)
293
}
0 commit comments