Skip to content
This repository was archived by the owner on Aug 7, 2021. It is now read-only.

Commit 9e093f0

Browse files
author
vakrilov
committed
refactor: review changes
1 parent ed7671a commit 9e093f0

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

hmr/hmr-update.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
import update from "../hot";
32
import { knownFolders } from "tns-core-modules/file-system";
43

hmr/hot-loader.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ const loader: loader.Loader = function (source, map) {
1717
const moduleRelativePath = this.resourcePath.replace(this.rootContext, ".");
1818
const modulePath = convertToUnixPath(moduleRelativePath);
1919
const ext = extname(modulePath).toLowerCase();
20-
const typeStyle = extMap[ext] || "unknown";
20+
const moduleType = extMap[ext] || "unknown";
2121

2222
const options = getOptions(this) || {};
2323
const alwaysSelfAccept = options.alwaysSelfAccept;
@@ -31,7 +31,7 @@ if (module.hot ${alwaysSelfAccept ? "" : shouldAutoAcceptCheck} ) {
3131
${trace ? traceCode : ""}
3232
module.hot.accept();
3333
module.hot.dispose(() => {
34-
global.hmrRefresh({ type: "${typeStyle}", path: "${modulePath}" });
34+
global.hmrRefresh({ type: "${moduleType}", path: "${modulePath}" });
3535
});
3636
}`;
3737

0 commit comments

Comments
 (0)