File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -24,11 +24,11 @@ export function createImportTransformPlugin(
2424 async resolveId ( source : string , importer : string | undefined , options ) {
2525 // Handle @socketsecurity /registry imports.
2626 if ( source . startsWith ( '@socketsecurity/registry' ) ) {
27+ const subpath = source . replace ( '@socketsecurity/registry' , '' )
2728 // Transform: @socketsecurity /registry → /abs/path/registry/src/index.ts
2829 // Transform: @socketsecurity /registry/lib/foo → /abs/path/registry/src/lib/foo.ts
29- const subpath = source . replace ( '@socketsecurity/registry' , '' ) || ''
3030 const targetPath = subpath
31- ? resolve ( actualProjectRoot , ' registry/src' , subpath + ' .ts' )
31+ ? resolve ( actualProjectRoot , ` registry/src${ subpath } .ts` )
3232 : resolve ( actualProjectRoot , 'registry/src/index.ts' )
3333 return { id : targetPath }
3434 }
You can’t perform that action at this time.
0 commit comments