{"id":17399247,"url":"https://github.com/feross/chrome-dgram","last_synced_at":"2025-04-08T03:13:31.829Z","repository":{"id":11741237,"uuid":"14268904","full_name":"feross/chrome-dgram","owner":"feross","description":"Use the Node `dgram` API in Chrome Apps","archived":false,"fork":false,"pushed_at":"2023-12-07T15:03:23.000Z","size":105,"stargazers_count":38,"open_issues_count":1,"forks_count":16,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-31T18:20:00.057Z","etag":null,"topics":["chrome-apps","chrome-dgram","chrome-extension","dgram","javascript","nodejs","udp"],"latest_commit_sha":null,"homepage":"https://webtorrent.io","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/feross.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2013-11-10T01:50:22.000Z","updated_at":"2025-02-11T15:47:29.000Z","dependencies_parsed_at":"2024-06-18T14:08:33.342Z","dependency_job_id":null,"html_url":"https://github.com/feross/chrome-dgram","commit_stats":{"total_commits":119,"total_committers":9,"mean_commits":"13.222222222222221","dds":"0.10924369747899154","last_synced_commit":"da066d87dde3783fdb57ced1c7edc4cba50bf33d"},"previous_names":[],"tags_count":29,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/feross%2Fchrome-dgram","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/feross%2Fchrome-dgram/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/feross%2Fchrome-dgram/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/feross%2Fchrome-dgram/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/feross","download_url":"https://codeload.github.com/feross/chrome-dgram/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247767236,"owners_count":20992548,"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":["chrome-apps","chrome-dgram","chrome-extension","dgram","javascript","nodejs","udp"],"created_at":"2024-10-16T15:14:02.231Z","updated_at":"2025-04-08T03:13:31.812Z","avatar_url":"https://github.com/feross.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# chrome-dgram [![travis][travis-image]][travis-url] [![npm][npm-image]][npm-url] [![downloads][downloads-image]][downloads-url] [![javascript style guide][standard-image]][standard-url]\n\n[travis-image]: https://img.shields.io/travis/feross/chrome-dgram/master.svg\n[travis-url]: https://travis-ci.org/feross/chrome-dgram\n[npm-image]: https://img.shields.io/npm/v/chrome-dgram.svg\n[npm-url]: https://npmjs.org/package/chrome-dgram\n[downloads-image]: https://img.shields.io/npm/dm/chrome-dgram.svg\n[downloads-url]: https://npmjs.org/package/chrome-dgram\n[standard-image]: https://img.shields.io/badge/code_style-standard-brightgreen.svg\n[standard-url]: https://standardjs.com\n\n### Use the Node `dgram` API in Chrome Apps\n\nThis module lets you use the Node.js [dgram](http://nodejs.org/api/dgram.html) (UDP) API in [Chrome Packaged Apps](http://developer.chrome.com/apps/about_apps.html).\n\nInstead of learning the quirks of Chrome's `chrome.sockets` API for networking in Chrome Apps just **use the higher-level node API you're familiar with**. Then, compile your code with [browserify](https://github.com/substack/node-browserify) and you're all set!\n\nThis module is used by [webtorrent](https://github.com/feross/webtorrent).\n\n## install\n\n```\nnpm install chrome-dgram\n```\n\n## methods\n\nUse node's `dgram` API, including all parameter list shorthands and variations.\n\nExample UDP client/bind:\n\n```js\nvar dgram = require('chrome-dgram')\n\nvar sock = dgram.createSocket('udp4')\n\nsock.send('beep', 0, 'beep'.length, 1337, '127.0.0.1')\n\nsock.on('message', function (data, rInfo) {\n  console.log('Got data from ' + rInfo.address + ':' + rInfo.port)\n  console.log(data)\n})\n```\n\nSee nodejs.org for full API documentation: [dgram](http://nodejs.org/api/dgram.html)\n\n## contribute\n\nTo run tests, use `npm test`. The tests will run TCP and UDP servers and launch a few different Chrome Packaged Apps with browserified client code. The tests currently require Chrome Canary on Mac. If you're on Windows or Linux, feel free to send a pull request to fix this limitation.\n\n## license\n\nMIT. Copyright (c) [Feross Aboukhadijeh](http://feross.org) \u0026 John Hiesey.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffeross%2Fchrome-dgram","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffeross%2Fchrome-dgram","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffeross%2Fchrome-dgram/lists"}