
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
input-proxy
Advanced tools
Reason
Forgetting to restringify your JSON into the input? Tired of writing the same function to unparse the JSON just for one value?
I sure did! So I wrapped my HTMLInputElement in a Proxy, and wrote some get and set methods to deal with just that.
Benefits
Pass in an HTMLInputElement, and then the value becomes a JSON object that you can access just be requesting the key.
import { IP } from '../input-proxy.js';
const input = document.getElementById('StoresJSON');
const wrappedInput = IP(input);
wrappedInput.name = 'John'; //
wrappedInput.name; // 'John'
// Access the input values like so
input.value; // '{ "name": "John" }'
// or
wrappedInput.__value; // '{ "name": "John" }'
// If a key hasn't been set or is deleted,
// InputProxy returns null
delete wrappedInput.name;
wrappedInput.name; // null
WARNING
To prevent issues with JSON.stringify, on creation InputProxy sets the value of the element passed in to be '{}'.
FAQs
Removes some of the hassle when storing JSON in an input.
We found that input-proxy demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.