Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
react-international-phone
Advanced tools
🤙 International phone input component for React
$ npm i react-international-phone
import { useState } from 'react';
import { PhoneInput } from 'react-international-phone';
import 'react-international-phone/style.css';
const App = () => {
const [phone, setPhone] = useState('');
return (
<div>
<PhoneInput
defaultCountry="ua"
value={phone}
onChange={(phone) => setPhone(phone)}
/>
</div>
);
};
Find the full API reference on official documentation.
You can encounter some breaking changes after update from v1 to v2
Checkout migration document that contains a list of breaking changes and ways to migrate.
2.0.0 (2023-03-10)
cursor: fix cursor position on autofocus (a7805fb)
cursor: set cursor position on initialization (4176553)
history: add history initial value function setter, fix state comparing (5893db6)
PhoneInput: fix call onChange callback after redo/undo and country change (e8f5ffc)
store country in history, update country flag on undo/redo (8259173)
usePhoneInput: fix dial code population on phone removal after the first render (2b14c61)
usePhoneInput: remove double rendering on initialization (241e3e1)
refactor!: remove usePhone hook, change hideSpaceAfterDialCode with charAfterDialCode (69731ae)
usePhone
hook has been removedhideSpaceAfterDialCode
prop was changed with charAfterDialCode
FAQs
☎️ International phone input component for React
The npm package react-international-phone receives a total of 80,305 weekly downloads. As such, react-international-phone popularity was classified as popular.
We found that react-international-phone demonstrated a healthy version release cadence and project activity because the last version was released less than 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.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.