{"id":16125722,"url":"https://github.com/dy/arraybuffer-to-string","last_synced_at":"2025-10-28T07:06:16.752Z","repository":{"id":57184214,"uuid":"95609139","full_name":"dy/arraybuffer-to-string","owner":"dy","description":"Convert ArrayBuffer to string","archived":false,"fork":false,"pushed_at":"2018-11-20T04:05:51.000Z","size":9,"stargazers_count":24,"open_issues_count":1,"forks_count":5,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-24T23:28:44.397Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/dy.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":"2017-06-27T23:25:36.000Z","updated_at":"2025-03-15T20:58:46.000Z","dependencies_parsed_at":"2022-09-14T08:50:22.014Z","dependency_job_id":null,"html_url":"https://github.com/dy/arraybuffer-to-string","commit_stats":null,"previous_names":["dfcreative/arraybuffer-to-string"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/dy/arraybuffer-to-string","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dy%2Farraybuffer-to-string","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dy%2Farraybuffer-to-string/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dy%2Farraybuffer-to-string/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dy%2Farraybuffer-to-string/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dy","download_url":"https://codeload.github.com/dy/arraybuffer-to-string/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dy%2Farraybuffer-to-string/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":281397645,"owners_count":26493977,"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","status":"online","status_checked_at":"2025-10-28T02:00:06.022Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":[],"created_at":"2024-10-09T21:31:06.964Z","updated_at":"2025-10-28T07:06:16.724Z","avatar_url":"https://github.com/dy.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# arraybuffer-to-string [![unstable](https://img.shields.io/badge/stability-unstable-orange.svg)](http://github.com/badges/stability-badges) [![Build Status](https://img.shields.io/travis/dy/arraybuffer-to-string.svg)](https://travis-ci.org/dy/arraybuffer-to-string)\n\nConvert _ArrayBuffer_ to string with optional encoding.\n\n[![npm install arraybuffer-to-string](https://nodei.co/npm/arraybuffer-to-string.png?mini=true)](https://npmjs.org/package/arraybuffer-to-string/)\n\n```js\nvar ab2str = require('arraybuffer-to-string')\n\nvar uint8 = new Uint8Array([ 72, 101, 108, 108, 111, 32, 87, 111, 114, 108, 100, 33 ])\n\nab2str(uint8) // 'Hello World!'\nab2str(uint8, 'base64') // 'SGVsbG8gV29ybGQh'\nab2str(uint8, 'hex') // '48656c6c6f20576f726c6421'\nab2str(uint8, 'iso-8859-2') // 'Hello World!'\n```\n\n### var str = arrayBufferToString(buffer, encoding='utf8')\n\nConvert ArrayBuffer/ArrayBufferView/Array `buffer` to string with defined encoding. Available encoding: `utf8`, `binary`, `base64`, `hex`, `ascii`, `latin1`, `ucs2`, `utf16` and [many others](https://developer.mozilla.org/en-US/docs/Web/API/TextDecoder/encoding).\n\nNote: in browser it relies on [TextDecoder API](https://developer.mozilla.org/en-US/docs/Web/API/TextDecoder/decode), so if you are dealing with charsets other than `utf8`, `ascii`, `binary` or `base64` in old browsers, please include [encoding polyfill](https://github.com/inexorabletash/text-encoding).\n\n### Related\n\n* [string-to-arraybuffer](https://github.com/dy/string-to-arraybuffer) − convert string to arraybuffer.\n* [create-data-uri](https://www.npmjs.com/package/create-data-uri) − convert binary data to datauri string.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdy%2Farraybuffer-to-string","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdy%2Farraybuffer-to-string","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdy%2Farraybuffer-to-string/lists"}