Skip to content

Browserify support #7

@gre

Description

@gre

Hi, socket-ntp is currently not browserify compliant. Here is how we can make it compliant:

in package.json, add:

"browser": "client/ntp"

in client/ntp.js:

  if (typeof require === 'function') {
    module.exports = ntp;
  }
  else if (typeof define === 'function' && define.amd) {
    define('ntp', [], function () {
      return ntp;
    });
  } else {
    root.ntp = ntp;
  }

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions