@module-federation/fmr
Advanced tools
Comparing version 0.0.6 to 0.0.7
{ | ||
"name": "@module-federation/fmr", | ||
"version": "0.0.6", | ||
"version": "0.0.7", | ||
"license": "MIT", | ||
"main": "./src/index.js", | ||
"description": "Hot reloading for Federated Modules", | ||
"keywords": [ | ||
"hmr", | ||
"live reload", | ||
"module federation", | ||
"federated module", | ||
"fmr" | ||
], | ||
"repository": { | ||
"url": "https://github.com/module-federation/FMR-issues/" | ||
}, | ||
"dependencies": { | ||
@@ -18,0 +7,0 @@ "chalk": "^4.1.1", |
@@ -119,6 +119,6 @@ const tcpPortUsed = require("tcp-port-used"); | ||
async prepareSocket(callback) { | ||
prepareSocket() { | ||
// if the socket server has mounted to the port, | ||
// open a connection to it | ||
await tcpPortUsed.waitUntilUsed(40001, "127.0.0.1").then( | ||
return tcpPortUsed.waitUntilUsed(40001, "127.0.0.1").then( | ||
() => { | ||
@@ -143,6 +143,3 @@ this.liveReload = new WebSocket("ws://localhost:40001"); | ||
); | ||
}); | ||
}, | ||
@@ -153,5 +150,2 @@ (err) => { | ||
); | ||
callback() | ||
} | ||
@@ -170,5 +164,5 @@ | ||
// so that we can send afterEmit events to the socket later | ||
compiler.hooks.beforeRun.tapAsync("CreateSocketConnectionPlugin", (params, callback) => { | ||
compiler.hooks.environment.tap("CreateSocketConnectionPlugin", () => { | ||
try { | ||
this.prepareSocket(callback); | ||
this.prepareSocket(); | ||
} catch (e) { | ||
@@ -175,0 +169,0 @@ this.infrastructureLogger && this.infrastructureLogger.error(e); |
@@ -36,6 +36,6 @@ const chalk = require("chalk"); | ||
let returnObject = { | ||
data: data || undefined, | ||
sender: sender || "UNKNOWN_SENDER", | ||
type: type || "UNKNOWN_TYPE", | ||
timestamp: timestamp || undefined, | ||
data: data ?? undefined, | ||
sender: sender ?? "UNKNOWN_SENDER", | ||
type: type ?? "UNKNOWN_TYPE", | ||
timestamp: timestamp ?? undefined, | ||
}; | ||
@@ -42,0 +42,0 @@ if (!sender) handleNoSender(socket, message); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
26612
19
722
4