
Research
Security News
Malicious PyPI Package Exploits Deezer API for Coordinated Music Piracy
Socket researchers uncovered a malicious PyPI package exploiting Deezer’s API to enable coordinated music piracy through API abuse and C2 server control.
@rematch/select
Advanced tools
Selectors plugin for Rematch.
npm install @rematch/select
import selectorsPlugin from '@rematch/select'
import { init } from '@rematch/core'
const select = selectorsPlugin()
init({
plugins: [select]
})
selectors: { [string]: (state, ...params) => any }
Selectors are read-only snippets of state.
{
name: 'cart',
state: [{
price: 42.00,
amount: 3,
}],
selectors: {
total(state) {
return state.reduce((a, b) => a + (b.price * b.amount), 0)
}
}
}
note: selector state does not refer to the complete state, only the state within the model
Selectors can be called anywhere within your app.
import { select, getState } from '@rematch/core'
select.cart.total(getState())
Selectors can also be used with memoization libraries like reselect.
import { createSelector } from 'reselect'
{
selectors: {
total: createSelector(
state => state.reduce((a, b) => a + (b.price * b.amount), 0)
)
}
}
FAQs
Selectors plugin for Rematch
The npm package @rematch/select receives a total of 6,545 weekly downloads. As such, @rematch/select popularity was classified as popular.
We found that @rematch/select demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 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.
Research
Security News
Socket researchers uncovered a malicious PyPI package exploiting Deezer’s API to enable coordinated music piracy through API abuse and C2 server control.
Research
The Socket Research Team discovered a malicious npm package, '@ton-wallet/create', stealing cryptocurrency wallet keys from developers and users in the TON ecosystem.
Security News
Newly introduced telemetry in devenv 1.4 sparked a backlash over privacy concerns, leading to the removal of its AI-powered feature after strong community pushback.