Skip to content
This repository was archived by the owner on Jul 19, 2022. It is now read-only.
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ module.exports = function (config = {}) {
log.all(id, 'looking in aliases')
for (let [aliasName, aliasPath] of Object.entries(alias)) {
log.all(id, 'looking in aliases', aliasName)
if (id.startsWith(aliasName + path.sep)) {
if (id.startsWith(aliasName + '/') || id.startsWith(aliasName + '\\')) {
log.match(id, 'matched alias', aliasName, aliasPath)
let importPath = path.resolve(path.join(aliasPath, id.substring(aliasName.length)))
let filepath = await findFile(importPath)
Expand Down