Skip to content

Commit

Permalink
Update src/resolve.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
pi0 committed Aug 11, 2022
1 parent 1c264ea commit 25e618e
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/resolve.ts
Expand Up @@ -60,6 +60,7 @@ function _resolve (id: string, opts: ResolveOptions = {}): string {
for (const url of _urls) {
if (url.protocol === 'file:') {
urls.push(new URL('./', url))
// If url is directory
urls.push(new URL(joinURL(url.pathname, '_index.js'), url))
// TODO: Remove in next major version seems not necessary
urls.push(new URL('./node_modules', url))
Expand Down

0 comments on commit 25e618e

Please sign in to comment.