
Security News
New CVE Forecasting Tool Predicts 47,000 Disclosures in 2025
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
web-share-shim
Advanced tools
A polyfill for the WebShare API. It provides `navigator.share()` so you can share content on any device via WhatsApp, Telegram, Facebook, e-mail, and SMS. Try the [demo](http://nimiq.github.io/web-share-shim/demo/)! The whole package is 9.6kB minified, 4k
A polyfill for the WebShare API. It provides navigator.share()
so you can share content on any device via WhatsApp, Telegram, Facebook, e-mail, and SMS.
Try the demo! The whole package is 9.6kB minified, 4kB gzipped and licensed under the MIT License.
Open the share dialog by calling navigator.share
:
navigator.share({
title: 'Web Share Shim',
text: 'Check out Web Share Shim — it rocks!',
url: 'http://nimiq.github.io/web-share-shim',
})
.then( _ => console.log('Successful share'))
.catch( error => console.log('Error sharing', error));
Attribute | Options | Default | Description |
---|---|---|---|
title | String | "" | A short title of what you are sharing. |
text | String | "" | A text describing what you are sharing. |
url | URL as String | "" | A link to what you are sharing. |
facebookId | number | "158651941570418" | ID of your facebook app if you want to support sharing to facebook on a desktop device. (default ID for demo only) |
You need to have gulp and all dependencies installed.
npm install
npm install gulp
Then run gulp
to build web-share-shim.bundle.min.js
.
FAQs
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
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Research
Security News
Eight new malicious Firefox extensions impersonate games, steal OAuth tokens, hijack sessions, and exploit browser permissions to spy on users.