{"id":15381879,"url":"https://github.com/justinribeiro/webnfc-reader","last_synced_at":"2025-02-28T08:30:25.963Z","repository":{"id":57123483,"uuid":"140359859","full_name":"justinribeiro/webnfc-reader","owner":"justinribeiro","description":"A Polymer 3 / lit-element web component that uses WebNFC to read NFC tags.","archived":false,"fork":false,"pushed_at":"2019-04-09T23:20:58.000Z","size":16,"stargazers_count":9,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-10-05T09:58:19.533Z","etag":null,"topics":["litelement","polymer","webcomponent","webnfc"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/@justinribeiro/webnfc-reader","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/justinribeiro.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-07-10T01:17:27.000Z","updated_at":"2020-05-11T19:42:37.000Z","dependencies_parsed_at":"2022-08-27T09:11:07.824Z","dependency_job_id":null,"html_url":"https://github.com/justinribeiro/webnfc-reader","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justinribeiro%2Fwebnfc-reader","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justinribeiro%2Fwebnfc-reader/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justinribeiro%2Fwebnfc-reader/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/justinribeiro%2Fwebnfc-reader/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/justinribeiro","download_url":"https://codeload.github.com/justinribeiro/webnfc-reader/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":219871224,"owners_count":16560621,"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":["litelement","polymer","webcomponent","webnfc"],"created_at":"2024-10-01T14:29:06.186Z","updated_at":"2024-10-16T19:03:21.788Z","avatar_url":"https://github.com/justinribeiro.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![npm version](https://badge.fury.io/js/%40justinribeiro%2Fwebnfc-reader.svg)](https://badge.fury.io/js/%40justinribeiro%2Fwebnfc-reader)\n\n# \\\u003cwebnfc-reader\\\u003e\n\n\u003e A web component that uses [WebNFC](https://w3c.github.io/web-nfc/) to read NFC tags.\n\n## Features\n\n* Props down / events up model: set watch options and simply listen for events via `addEventListener`.\n* `sound` attribute uses Web Audio API to make a beep when a tag is read (so hip)\n* Built as a web component on Polymer 3 / LitElement\n\n## Install\n\nThis web component is built with Polymer 3 and ES modules in mind and is\navailable on NPM:\n\nInstall webnfc-reader:\n\n```sh\nnpm i @justinribeiro/webnfc-reader\n# or\nyarn add @justinribeiro/webnfc-reader\n```\n\nAfter install, import into your project:\n\n```js\nimport 'webnfc-reader';\n```\n\nFinally, use as required:\n\n```html\n\u003cwebnfc-reader sound\u003e\u003c/webnfc-reader\u003e\n```\n\n## Chrome Flag Required\n\nCurrently, WebNFC is behind a Chrome flag on Android. To enable, go to chrome://flags and enabled WebNFC on an Android compatible device.\n\n## Attributes\n\n | Name | Description | Default |\n | --- | --- | --- |\n | `src` | NFCWatchOptions.url property denotes the URL pattern which is used for matching the Web NFC Id of Web NFC messages which are being read. The default value \"\" means that no matching happens. | `` |\n | `recordtype` | NFCWatchOptions.recordType property denotes the string value which is used for matching the type property of each NFCRecord object in a Web NFC message. The default value \"\" means that no matching happens. | `` |\n | `mediatype` | NFCWatchOptions.mediaType property denotes the match pattern which is used for matching the type property of each NFCRecord object in a Web NFC message. The default value \"\" means that no matching happens. | `` |\n | `mode` | NFCWatchOptions.mode property denotes the NFCWatchMode value telling whether only Web NFC content or any NFC content will be watched. | `any` |\n | `verbose` | Status messages sent through custom event `webnfc-reader-status` | false |\n | `sound` | Make a beep sound through Web Audio API when tag is read | false |\n\n## Events\n\n | Name | Description\n | --- | --- |\n | `webnfc-reader-status` | Watch and status messages |\n | `webnfc-reader-watch` | Receive WebNFC records on tag read |","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjustinribeiro%2Fwebnfc-reader","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjustinribeiro%2Fwebnfc-reader","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjustinribeiro%2Fwebnfc-reader/lists"}