8,
join(__dirname, 'worker.js'),
{
- errorHandler: (e: Error) => console.error(e),
- onlineHandler: () => console.log('Worker is online')
+ errorHandler: (e: Error) => {
+ console.error(e)
+ },
+ onlineHandler: () => {
+ console.log('Worker is online')
+ }
}
)
8,
join(__dirname, 'worker.js'),
{
- errorHandler: (e: Error) => console.error(e),
- onlineHandler: () => console.log('Worker is online')
+ errorHandler: (e: Error) => {
+ console.error(e)
+ },
+ onlineHandler: () => {
+ console.log('Worker is online')
+ }
}
)
"c8": "^7.12.0",
"eslint": "^8.31.0",
"eslint-config-standard": "^17.0.0",
- "eslint-config-standard-with-typescript": "^24.0.0",
+ "eslint-config-standard-with-typescript": "^26.0.0",
"eslint-define-config": "^1.13.0",
"eslint-import-resolver-typescript": "^3.5.2",
"eslint-plugin-import": "^2.26.0",
"eslint-plugin-spellcheck": "^0.0.20",
"eslint-plugin-tsdoc": "^0.2.17",
"expect": "^29.3.1",
- "husky": "^8.0.2",
+ "husky": "^8.0.3",
"lint-staged": "^13.1.0",
"microtime": "^3.1.1",
"mocha": "^10.2.0",
}
},
"node_modules/eslint-config-standard-with-typescript": {
- "version": "24.0.0",
- "resolved": "https://registry.npmjs.org/eslint-config-standard-with-typescript/-/eslint-config-standard-with-typescript-24.0.0.tgz",
- "integrity": "sha512-vEnGXZ5aiR1enl9652iIP4nTpY3GPcNEwuhrsPbKO3Ce3D6T3yCqZdkUPk8nJetfdL/yO0DLsHg2d/l9iECIdg==",
+ "version": "26.0.0",
+ "resolved": "https://registry.npmjs.org/eslint-config-standard-with-typescript/-/eslint-config-standard-with-typescript-26.0.0.tgz",
+ "integrity": "sha512-TluIWunQo76qp4MHyYIaTT+sN2q2v/jTeE3Dj4rXsSbx27GOUEOujhJaAL3v9dHVQelAK13gZ5Jy9IWnWCyFrg==",
"dev": true,
"dependencies": {
"@typescript-eslint/parser": "^5.0.0",
}
},
"node_modules/husky": {
- "version": "8.0.2",
- "resolved": "https://registry.npmjs.org/husky/-/husky-8.0.2.tgz",
- "integrity": "sha512-Tkv80jtvbnkK3mYWxPZePGFpQ/tT3HNSs/sasF9P2YfkMezDl3ON37YN6jUUI4eTg5LcyVynlb6r4eyvOmspvg==",
+ "version": "8.0.3",
+ "resolved": "https://registry.npmjs.org/husky/-/husky-8.0.3.tgz",
+ "integrity": "sha512-+dQSyqPh4x1hlO1swXBiNb2HzTDN1I2IGLQx1GrBuiqFJfoMrnZWwVmatvSiO+Iz8fBUnf+lekwNo4c2LlXItg==",
"dev": true,
"bin": {
"husky": "lib/bin.js"
"dev": true
},
"eslint-config-standard-with-typescript": {
- "version": "24.0.0",
- "resolved": "https://registry.npmjs.org/eslint-config-standard-with-typescript/-/eslint-config-standard-with-typescript-24.0.0.tgz",
- "integrity": "sha512-vEnGXZ5aiR1enl9652iIP4nTpY3GPcNEwuhrsPbKO3Ce3D6T3yCqZdkUPk8nJetfdL/yO0DLsHg2d/l9iECIdg==",
+ "version": "26.0.0",
+ "resolved": "https://registry.npmjs.org/eslint-config-standard-with-typescript/-/eslint-config-standard-with-typescript-26.0.0.tgz",
+ "integrity": "sha512-TluIWunQo76qp4MHyYIaTT+sN2q2v/jTeE3Dj4rXsSbx27GOUEOujhJaAL3v9dHVQelAK13gZ5Jy9IWnWCyFrg==",
"dev": true,
"requires": {
"@typescript-eslint/parser": "^5.0.0",
"dev": true
},
"husky": {
- "version": "8.0.2",
- "resolved": "https://registry.npmjs.org/husky/-/husky-8.0.2.tgz",
- "integrity": "sha512-Tkv80jtvbnkK3mYWxPZePGFpQ/tT3HNSs/sasF9P2YfkMezDl3ON37YN6jUUI4eTg5LcyVynlb6r4eyvOmspvg==",
+ "version": "8.0.3",
+ "resolved": "https://registry.npmjs.org/husky/-/husky-8.0.3.tgz",
+ "integrity": "sha512-+dQSyqPh4x1hlO1swXBiNb2HzTDN1I2IGLQx1GrBuiqFJfoMrnZWwVmatvSiO+Iz8fBUnf+lekwNo4c2LlXItg==",
"dev": true
},
"iconv-lite": {
"c8": "^7.12.0",
"eslint": "^8.31.0",
"eslint-config-standard": "^17.0.0",
- "eslint-config-standard-with-typescript": "^24.0.0",
+ "eslint-config-standard-with-typescript": "^26.0.0",
"eslint-define-config": "^1.13.0",
"eslint-import-resolver-typescript": "^3.5.2",
"eslint-plugin-import": "^2.26.0",
"eslint-plugin-spellcheck": "^0.0.20",
"eslint-plugin-tsdoc": "^0.2.17",
"expect": "^29.3.1",
- "husky": "^8.0.2",
+ "husky": "^8.0.3",
"lint-staged": "^13.1.0",
"microtime": "^3.1.1",
"mocha": "^10.2.0",
worker.on('error', this.opts.errorHandler ?? EMPTY_FUNCTION)
worker.on('online', this.opts.onlineHandler ?? EMPTY_FUNCTION)
worker.on('exit', this.opts.exitHandler ?? EMPTY_FUNCTION)
- worker.once('exit', () => this.removeWorker(worker))
+ worker.once('exit', () => {
+ this.removeWorker(worker)
+ })
this.workers.push(worker)