
Security News
The Hidden Blast Radius of the Axios Compromise
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.
@yaireo/ui-switch
Advanced tools
I wanted a solid, beautiful Switch component, with absolutly minimal footprint.
I did not want to install a full components-lib, even if I would be using only a single component, I wanted it to be really lightweight but also highly customizable, and CSS variables are perfect for this, since they are much better than pre-compiled variabled, since they are computed on-the-fly, the CSS itself if kept to a minimum, when wanted to create different design versions of the Switch component.
npm i @yaireo/ui-switch
import Switch from '@yaireo/ui-switch'
import '@yaireo/ui-switch/src/switch.scss'
// or the pre-compiled CSS:
// import '@yaireo/ui-switch/dist/switch.css'
// use in JSX:
<form>
<Switch checked={checked} onChange={onSwitchChange}/>
<Switch textRight>Label on the right</Switch>
<Switch disabled checked>Disabled</Switch>
<Switch indeterminate>Indeterminate</Switch>
<Switch style={{'--size':'12px', '--thumb-scale':2.2, 'thumb-color-on':'green'}}>Inline styles</Switch>
</form>
> npm install
> gulp
FAQs
lightweight React Switch component using CSS variables
We found that @yaireo/ui-switch 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
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.

Research
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.

Research
Malicious versions of the Telnyx Python SDK on PyPI delivered credential-stealing malware via a multi-stage supply chain attack.