Skip to content

Commit

Permalink
Merge pull request #1 from jsleuth/feature/windows_support
Browse files Browse the repository at this point in the history
feat(build): add support for windows filesystem
  • Loading branch information
pat841 authored Jun 14, 2018
2 parents 965222f + 493ddd3 commit 5571733
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/AureliaDependenciesPlugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ class ParserPlugin {
parser.plugin("evaluate Identifier imported var.moduleName", (expr: Webpack.MemberExpression) => {
if (expr.property.name === "moduleName" &&
expr.object.name === "PLATFORM" &&
expr.object.type === "Identifier") {
String(expr.object.type) === "Identifier") {
return new BasicEvaluatedExpression().setIdentifier("PLATFORM.moduleName").setRange(expr.range);
}
return undefined;
Expand All @@ -58,8 +58,8 @@ class ParserPlugin {
// PLATFORM.moduleName("id");
parser.plugin("evaluate MemberExpression", (expr: Webpack.MemberExpression) => {
if (expr.property.name === "moduleName" &&
(expr.object.type === "MemberExpression" && expr.object.property.name === "PLATFORM" ||
expr.object.type === "Identifier" && expr.object.name === "PLATFORM")) {
(String(expr.object.type) === "MemberExpression" && expr.object.property.name === "PLATFORM" ||
String(expr.object.type) === "Identifier" && expr.object.name === "PLATFORM")) {
return new BasicEvaluatedExpression().setIdentifier("PLATFORM.moduleName").setRange(expr.range);
}
return undefined;
Expand Down
1 change: 1 addition & 0 deletions src/PreserveModuleNamePlugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ export class PreserveModuleNamePlugin {
}

// Metadata?
moduleId = moduleId.replace(/\\/g, '/');
if (module.meta) {
module.meta['aurelia-id'] = moduleId;
}
Expand Down

0 comments on commit 5571733

Please sign in to comment.