We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7e39d04 commit 8b46a6cCopy full SHA for 8b46a6c
packages/nextjs/src/config/loaders/wrappingLoader.ts
@@ -182,6 +182,10 @@ export default function wrappingLoader(
182
183
const componentTypeMatch = path.posix
184
.normalize(path.relative(appDir, this.resourcePath))
185
+ // Replace all backslashes with forward slashes (windows)
186
+ .replace(/\\/g, '/')
187
+ // Add a slash at the beginning
188
+ .replace(/(.*)/, '/$1')
189
// eslint-disable-next-line @sentry-internal/sdk/no-regexp-constructor
190
.match(new RegExp(`/\\/?([^/]+)\\.(?:${pageExtensionRegex})$`));
191
0 commit comments