
Security News
Scaling Socket from Zero to 10,000+ Organizations
Socket CEO Feross Aboukhadijeh shares lessons from scaling a developer security startup to 10,000+ organizations in this founder interview.
@trinitymirrordigital/state-manager
Advanced tools
@trinitymirrordigital/state-managerFor managing state in ET web components
import { State } from '@trinitymirrordigital/state-manager';
// Basic set up - pass keys you want to track.
const state = StateManager(['foo']); // will track changes to foo
// or you can pre-assign values
const state = StateManager(['foo'], {foo: 'bar'}); // will track changes to foo
// Add observer which will be called when there is a change to foo
state.addObserver = (state, oldState)=>{
// do something with change
}
// basic usage
state.foo = 'something'; // add observer called
// observer called with state {foo: 'something'} and oldState {foo: 'bar'}
state.foo = 'something'; // observer not called
// mass assign
state.massAssign = { foo: 'something else'}
// observer called with state {foo: 'something else'} and oldState {foo: 'something'}
// Get state
state.getState // return { foo: 'something else'}
FAQs
Managing state in web components
The npm package @trinitymirrordigital/state-manager receives a total of 1 weekly downloads. As such, @trinitymirrordigital/state-manager popularity was classified as not popular.
We found that @trinitymirrordigital/state-manager demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers 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
Socket CEO Feross Aboukhadijeh shares lessons from scaling a developer security startup to 10,000+ organizations in this founder interview.

Research
Socket Threat Research maps a rare inside look at OtterCookie’s npm-Vercel-GitHub chain, adding 197 malicious packages and evidence of North Korean operators.

Research
Socket researchers identified a malicious Chrome extension that manipulates Raydium swaps to inject an undisclosed SOL transfer, quietly routing fees to an attacker wallet.