Socket
Socket
Sign inDemoInstall

ndef

Package Overview
Dependencies
0
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    ndef

Library to create and parse NDEF messages.


Version published
Weekly downloads
177
decreased by-26.25%
Maintainers
1
Install size
48.1 kB
Created
Weekly downloads
 

Readme

Source

Library to create and parse NDEF messages.

ndef = require('ndef');

message = [
    ndef.textRecord("hello, world")
];

bytes = ndef.encodeMessage(message);

// do something useful with bytes: write to a tag or send to a peer
  
records = ndef.decodeMessage(bytes);

ndef.text.decodePayload(records[0].payload);

// prints 'hello, world'
        

See the examples directory and the mifare classic examples for more information on creating and decoding messages.

See the phonegap-nfc documentation for additional info.

Keywords

FAQs

Last updated on 11 May 2018

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc