
Security News
/Research
node-ipc npm Package Compromised in Supply Chain Attack
Socket detected malicious node-ipc versions with obfuscated stealer/backdoor behavior in a developing npm supply chain attack.
A helper class that allows you to hand off data from server to client.
Iso is a class. You instantiate it, add your markup, add some data to go with it, and render it. On the clientside Iso picks up what you sent down and gives it back to you so you can bring your content to life.
The constructor takes in a name which is then used to build up a unique key for every added html,
and a renderer which is used to determine how the data is prestented to the client. By default
the renderer renders the markup into a div and the data into a script tag.
You provide the markup to add and some data you wish to pass down, and iso will save it internally.
Once you're ready to collect your html you call render and a string will be returned to you.
onNode is a function that is called with the data, and a reference to the container node on the
DOM. The selector is a function that you can configure to find the state and nodes on the DOM
and return them.
The returned payload from selector should be an Object which contains the state and node pair
for each unique key.
{
"foobar": {
state: { name: "foo" },
node: DOMNode,
},
}
Sample:
// server.js
const iso = new Iso()
request.get('/', function (req, res) {
iso.add('<div>Hello, World!</div>', { someSampleData: 'Hello, World!' })
res.render(iso.render())
})
// client.js
Iso.bootstrap(function (state, node) {
// Now I do something with this data, perhaps run it through some library and then append
// the result to node?
})
FAQs
Isomorphic applications helper
The npm package iso receives a total of 904 weekly downloads. As such, iso popularity was classified as not popular.
We found that iso 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
/Research
Socket detected malicious node-ipc versions with obfuscated stealer/backdoor behavior in a developing npm supply chain attack.

Security News
TeamPCP and BreachForums are promoting a Shai-Hulud supply chain attack contest with a $1,000 prize for the biggest package compromise.

Security News
Packagist urges PHP projects to update Composer after a GitHub token format change exposed some GitHub Actions tokens in CI logs.