{"id":13826849,"url":"https://github.com/housinghq/react-share-button","last_synced_at":"2026-02-06T09:13:39.926Z","repository":{"id":123855794,"uuid":"84714366","full_name":"housinghq/react-share-button","owner":"housinghq","description":"📱 React share button component with web-share api and fallback modal with native intent urls","archived":false,"fork":false,"pushed_at":"2017-03-21T10:14:40.000Z","size":4214,"stargazers_count":91,"open_issues_count":1,"forks_count":9,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-11-20T06:33:58.141Z","etag":null,"topics":["clipboard","facebook","intents","mail","react","share","twitter","web-share","whatsapp"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/housinghq.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2017-03-12T09:28:57.000Z","updated_at":"2024-03-21T17:10:50.000Z","dependencies_parsed_at":"2024-01-14T20:30:23.084Z","dependency_job_id":null,"html_url":"https://github.com/housinghq/react-share-button","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/housinghq/react-share-button","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/housinghq%2Freact-share-button","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/housinghq%2Freact-share-button/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/housinghq%2Freact-share-button/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/housinghq%2Freact-share-button/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/housinghq","download_url":"https://codeload.github.com/housinghq/react-share-button/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/housinghq%2Freact-share-button/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264380371,"owners_count":23599037,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["clipboard","facebook","intents","mail","react","share","twitter","web-share","whatsapp"],"created_at":"2024-08-04T09:01:45.394Z","updated_at":"2026-02-06T09:13:39.863Z","avatar_url":"https://github.com/housinghq.png","language":"JavaScript","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"readme":"# react-share-button\n\n\u003e A lightweight React Share Button for mobile web with web share api integration, native intent support and fallback.\n\n\u003cp align=\"center\"\u003e\n  \u003cspan display=\"inline-block\" margin-right=\"12\"\u003e\u003cimg src=\"demo.gif\" width=\"320\" height=\"560\"/\u003e\u003c/span\u003e\n  \u003cspan display=\"inline-block\"\u003e\u003cimg src=\"demo2.gif\" width=\"320\" height=\"560\"/\u003e\u003c/span\u003e\n\u003c/p\u003e\n\n## Features\n\n1. [Web Share Api](https://developers.google.com/web/updates/2016/10/navigator-share) (on Origin Trials experiment until April 2017)\n1. Share Modal Fallback for other browsers\n1. Share via Whatsapp, FB, Twitter, Mail or Copy on Clipboard\n\n## Installation\n\n```\nnpm install --save react-share-button\n```\n\n## Basic Usage\n\nTo get web-share API on your origin just [request a token for your origin.](https://docs.google.com/forms/d/e/1FAIpQLSfO0_ptFl8r8G0UFhT0xhV17eabG-erUWBDiKSRDTqEZ_9ULQ/viewform_)\nYou will get an email within 24 hrs with you key, then just add a meta tag\n```\n\u003cmeta http-equiv=\"origin-trial\" content=\"**insert your token as provided in the the email here**\"\u003e\n```\nKnow more about [OriginTrials](https://github.com/jpchase/OriginTrials/blob/gh-pages/developer-guide.md)\n\n**JSX**:\n```js\nimport ShareBtn from 'react-share-button';\n\n\u003cShareBtn\n  url={url}\n  text={text}\n  className='ib'\n  displayText='Share'\n/\u003e\n```\n**CSS**\n```css\n@import \"react-share-button/dist/ShareBtn\"\n```\n\n## Options\n\n### \u0026lt;ShareBtn/\u0026gt; Component\n\nprop|default|description\n----|-------|-----------\nclassName|''|Custom classnamem, you can style your button with this\nurl|''|The URL you want to share\ntext|''|The Text before the URL (E.g. Hey checkout this awesome property!!)\ndisplayText| Share |Any text you wanna write on button like Share Property\nonShareBtnClick| () =\u003e {} |A callback function when share button is clicked\nsharedBy| (medium) =\u003e {console.log('shared via ', medium)}|A callback function when user clicks on any share medium from share modal\n\n### Development\n```\ngit clone https://github.com/housinghq/react-share-button\ncd react-share-button\nnpm install\nnpm run storybook\n```\n\nOpen an issue before opening a PR. The UI in this package is for mobile only.\n\n### License\nMIT @ Loconsolutions\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhousinghq%2Freact-share-button","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhousinghq%2Freact-share-button","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhousinghq%2Freact-share-button/lists"}