human-signals
Advanced tools
Comparing version 4.3.1 to 5.0.0
@@ -10,3 +10,3 @@ import{constants}from"node:os"; | ||
const signals=getSignals(); | ||
return Object.fromEntries(signals.map(getSignalByName)); | ||
return Object.fromEntries(signals.map(getSignalByName)) | ||
}; | ||
@@ -33,5 +33,5 @@ | ||
const signalsA=Array.from({length},(value,number)=> | ||
getSignalByNumber(number,signals)); | ||
return Object.assign({},...signalsA); | ||
getSignalByNumber(number,signals) | ||
); | ||
return Object.assign({},...signalsA) | ||
}; | ||
@@ -43,3 +43,3 @@ | ||
if(signal===undefined){ | ||
return{}; | ||
return{} | ||
} | ||
@@ -58,4 +58,4 @@ | ||
} | ||
} | ||
}; | ||
}; | ||
@@ -68,8 +68,8 @@ | ||
if(signal!==undefined){ | ||
return signal; | ||
return signal | ||
} | ||
return signals.find((signalA)=>signalA.number===number); | ||
return signals.find((signalA)=>signalA.number===number) | ||
}; | ||
export const signalsByNumber=getSignalsByNumber(); |
export const getRealtimeSignals=()=>{ | ||
const length=SIGRTMAX-SIGRTMIN+1; | ||
return Array.from({length},getRealtimeSignal); | ||
return Array.from({length},getRealtimeSignal) | ||
}; | ||
@@ -6,0 +6,0 @@ |
@@ -11,3 +11,3 @@ import{constants}from"node:os"; | ||
const signals=[...SIGNALS,...realtimeSignals].map(normalizeSignal); | ||
return signals; | ||
return signals | ||
}; | ||
@@ -34,3 +34,3 @@ | ||
const number=supported?constantSignal:defaultNumber; | ||
return{name,number,description,supported,action,forced,standard}; | ||
return{name,number,description,supported,action,forced,standard} | ||
}; |
{ | ||
"name": "human-signals", | ||
"version": "4.3.1", | ||
"version": "5.0.0", | ||
"type": "module", | ||
@@ -54,9 +54,9 @@ "exports": { | ||
"devDependencies": { | ||
"@ehmicky/dev-tasks": "^2.0.71", | ||
"@ehmicky/dev-tasks": "^2.0.80", | ||
"ajv": "^8.12.0", | ||
"test-each": "^5.7.1" | ||
"test-each": "^6.0.0" | ||
}, | ||
"engines": { | ||
"node": ">=14.18.0" | ||
"node": ">=16.17.0" | ||
} | ||
} |
@@ -19,12 +19,2 @@ [![Node](https://img.shields.io/badge/-Node.js-808080?logo=node.js&colorA=404040&logoColor=66cc33)](https://www.npmjs.com/package/human-signals) | ||
# Hire me | ||
Please | ||
[reach out](https://www.linkedin.com/feed/update/urn:li:activity:7018596298127781890/) | ||
if you're looking for a Node.js API or CLI engineer (10 years of experience). | ||
Most recently I have been [Netlify Build](https://github.com/netlify/build)'s | ||
and [Netlify Plugins](https://www.netlify.com/products/build/plugins/)' | ||
technical lead for 2.5 years. I am available for full-time remote positions in | ||
either US or EU time zones. | ||
# Example | ||
@@ -64,3 +54,3 @@ | ||
This package works in Node.js >=14.18.0. | ||
This package works in Node.js >=16.17.0. | ||
@@ -67,0 +57,0 @@ This is an ES module. It must be loaded using |
415
25965
169