diff --git a/packages/uniwind/src/metro/resolvers.ts b/packages/uniwind/src/metro/resolvers.ts index d377720f..730fa2ef 100644 --- a/packages/uniwind/src/metro/resolvers.ts +++ b/packages/uniwind/src/metro/resolvers.ts @@ -93,7 +93,7 @@ export const webResolver = ({ const isIndex = segments.at(-1)?.startsWith('index.') const module = segments.at(-2) - if (!isIndex || module === undefined || !SUPPORTED_COMPONENTS.includes(module) || context.originModulePath.endsWith(`${module}/index.js`)) { + if (!isIndex || module === undefined || !SUPPORTED_COMPONENTS.includes(module) || context.originModulePath.endsWith(`${module}${sep}index.js`)) { return resolution }