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-whatsapp-button
Advanced tools
A simple react component to show a Whatsapp floating button.
A simple react component to show a Whatsapp floating button.
Content
You can install react-whatsapp-button by entering this command
npm i react-whatsapp-button
import React from "react";
import ReactWhatsappButton from "react-whatsapp-button";
function App() {
return (
<div className="App">
<ReactWhatsappButton
countryCode="51"
phoneNumber="987654321"
/>
</div>
)
}
export default App;
import React from "react";
import ReactWhatsappButton from "react-whatsapp-button";
function App() {
return (
<div className="App">
<ReactWhatsappButton
countryCode="51"
phoneNumber="987654321"
animated
/>
</div>
)
}
export default App;
import React from "react";
import ReactWhatsappButton from "react-whatsapp-button";
function App() {
return (
<div className="App">
<ReactWhatsappButton
countryCode="51"
phoneNumber="987654321"
style={{
backgroundColor: "#00a4f5",
right: "unset",
left: "10px",
}}
/>
</div>
)
}
export default App;
You can try all the variations here: https://react-whatsapp-button.vercel.app/?path=/story/whatsapp-button--default
Attribute | Type | Default | Required | Description |
---|---|---|---|---|
countryCode | string | "" | yes | country code without +. Example: 51 |
phoneNumber | string | "" | yes | Phone Number |
message | string | "" | no | Custom message |
animated | boolean | false | no | Add an animation to the button |
callback | function | () => {} | no | Add a callback function to the button |
style | object | {} | no | Modify the default style with a custom object |
Feel free to add a new pull request to improve this amazing package.
Thank you to all the people who already contributed to this project!
Kevin Riveros 💻 |
MIT
FAQs
A simple react component to show a Whatsapp floating button.
The npm package react-whatsapp-button receives a total of 82 weekly downloads. As such, react-whatsapp-button popularity was classified as not popular.
We found that react-whatsapp-button 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.
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.