{"id":23763868,"url":"https://github.com/tomashubelbauer/esm-dataview-getvarint","last_synced_at":"2026-04-13T08:31:01.162Z","repository":{"id":107986068,"uuid":"352112675","full_name":"TomasHubelbauer/esm-dataview-getvarint","owner":"TomasHubelbauer","description":"ESM (and non-ESM) JavaScript varint library","archived":false,"fork":false,"pushed_at":"2022-04-17T00:18:09.000Z","size":3,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-29T08:38:14.436Z","etag":null,"topics":["javascript","library","protobuf","sqlite","varint"],"latest_commit_sha":null,"homepage":"https://tomashubelbauer.github.io/esm-dataview-getvarint/index.js","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/TomasHubelbauer.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2021-03-27T15:50:55.000Z","updated_at":"2022-04-17T00:18:12.000Z","dependencies_parsed_at":"2024-06-04T13:09:02.542Z","dependency_job_id":null,"html_url":"https://github.com/TomasHubelbauer/esm-dataview-getvarint","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/TomasHubelbauer/esm-dataview-getvarint","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TomasHubelbauer%2Fesm-dataview-getvarint","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TomasHubelbauer%2Fesm-dataview-getvarint/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TomasHubelbauer%2Fesm-dataview-getvarint/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TomasHubelbauer%2Fesm-dataview-getvarint/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TomasHubelbauer","download_url":"https://codeload.github.com/TomasHubelbauer/esm-dataview-getvarint/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TomasHubelbauer%2Fesm-dataview-getvarint/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31746101,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-13T06:26:45.479Z","status":"ssl_error","status_checked_at":"2026-04-13T06:26:44.645Z","response_time":93,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["javascript","library","protobuf","sqlite","varint"],"created_at":"2024-12-31T22:13:43.913Z","updated_at":"2026-04-13T08:31:01.143Z","avatar_url":"https://github.com/TomasHubelbauer.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ESM DataView `getVarint`\n\nThis JavaScript library extends the `DataView` prototype to add a `getVarint`\nmethod.\n\nThe library is developed with Protobuf and SQLite varints in mind, but varints\nare used in other applications as well, like Bitcoin, Minecraft and many others.\n\n- [Protobuf varint](https://developers.google.com/protocol-buffers/docs/encoding#varints)\n- [SQLite varint](https://sqlite.org/src4/doc/trunk/www/varint.wiki)\n\n## Installation\n\n### `script` tag\n\n```js\n\u003cscript src=\"https://tomashubelbauer.github.io/esm-dataview-getvarint/index.js\"\u003e\u003c/script\u003e\n```\n\nFrom this point on, any `DataView` will have a `getVarint` method.\n\n### ES Modules (browser and Node)\n\nUse `--experimental-network-imports` with Node for HTTP(S) ESM URL support:\n\nhttps://nodejs.org/api/esm.html#https-and-http-imports\n\n```js\nimport 'https://tomashubelbauer.github.io/esm-dataview-getvarint/index.js';\n\n// From this point on, any `DataView` will have a `getVarint` method.\n```\n\n## Usage \u0026 API\n\n```js\n/** @type {DataView} */\nconst dataView = …;\n\n/** @typedef {{ value: number; byteLength: number; }} Varint */\n\n// Get a varint at the beginning of the data view\n/** @type {Varint} */\nconst varint = dataView.getVarint();\n\n// Get a varint at a given byte offset in the data view\n/** @type {Varint} */\nconst varint = dataView.getVarint(1);\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftomashubelbauer%2Fesm-dataview-getvarint","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftomashubelbauer%2Fesm-dataview-getvarint","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftomashubelbauer%2Fesm-dataview-getvarint/lists"}