{"id":20384184,"url":"https://github.com/levelz-file/js-bindings","last_synced_at":"2025-04-12T09:23:12.174Z","repository":{"id":228481974,"uuid":"766797286","full_name":"LevelZ-File/js-bindings","owner":"LevelZ-File","description":"JavaScript Parser \u0026 API for the LevelZ File Format","archived":false,"fork":false,"pushed_at":"2025-03-24T19:07:03.000Z","size":1264,"stargazers_count":1,"open_issues_count":2,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-26T04:21:45.407Z","etag":null,"topics":["javascript","js","levelz","nodejs","web"],"latest_commit_sha":null,"homepage":"https://levelz-file.github.io/js-bindings/","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/LevelZ-File.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},"funding":{"patreon":"gmitch215"}},"created_at":"2024-03-04T06:26:23.000Z","updated_at":"2025-03-15T04:10:49.000Z","dependencies_parsed_at":"2024-03-19T01:55:08.470Z","dependency_job_id":"e95efd5b-bdf9-4ef5-90b0-c5b775500830","html_url":"https://github.com/LevelZ-File/js-bindings","commit_stats":null,"previous_names":["levelz-file/js-bindings"],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LevelZ-File%2Fjs-bindings","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LevelZ-File%2Fjs-bindings/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LevelZ-File%2Fjs-bindings/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LevelZ-File%2Fjs-bindings/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LevelZ-File","download_url":"https://codeload.github.com/LevelZ-File/js-bindings/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248544441,"owners_count":21121954,"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":["javascript","js","levelz","nodejs","web"],"created_at":"2024-11-15T02:26:24.195Z","updated_at":"2025-04-12T09:23:12.143Z","avatar_url":"https://github.com/LevelZ-File.png","language":"JavaScript","funding_links":["https://patreon.com/gmitch215"],"categories":[],"sub_categories":[],"readme":"# levelz-js\n\n![GitHub License](https://img.shields.io/github/license/LevelZ-File/js-bindings)\n[![GitHub package.json version](https://img.shields.io/github/package-json/v/LevelZ-File/js-bindings)](https://www.npmjs.com/package/levelz-js)\n[![Static Badge](https://img.shields.io/badge/documentation-jsdoc-blue)](https://levelz-file.github.io/js-bindings)\n![NPM Downloads](https://img.shields.io/npm/d18m/levelz-js)\n\n\u003e JavaScript Bindings for the LevelZ File Format\n\n## Overview\n\nProvides JavaScript bindings for the LevelZ File Format.\n\n## Installation\n\n### System\n\n```bash\n# NPM\nnpm install levelz-js\n\n# Yarn\nyarn add levelz-js\n\n# Bun\nbun install levelz-js\n```\n\n### Web\n\n```html\n\u003c!-- Use Minified Version --\u003e\n\u003cscript src=\"https://levelz-file.github.io/js-bindings/levelz.min.js\"\u003e\u003c/script\u003e\n\n\u003c!-- Use Readable Version --\u003e\n\u003cscript src=\"https://levelz-file.github.io/js-bindings/levelz.js\"\u003e\u003c/script\u003e\n```\n\n## Usage\n\n```js\nimport { Coordinate2D } from 'levelz-js';\n\nconst coordinate = new Coordinate2D(1, 2);\nconsole.log(coordinate.toString()); // [1, 2]\n```\n\n```js\nimport * as fs from 'fs';\nimport { parseLevel } from 'levelz-js';\n\nconst txt = fs.readFileSync('my_level.lvlz', { encoding: 'utf-8' });\nconst level = parseLevel(txt);\n\nconsole.log(level.headers.get('type')) // 3\n```\n\n```js\nimport * as LevelZ from 'levelz-js'\n\nconst coordinate3D = new LevelZ.Coordinate3D(1, 2, 3);\nconsole.log(coordinate3D.toString()); // [1, 2, 3]\n\nconst level = new LevelZ.Level2D({'type': '3', 'spawn', '[0, 0, 0]'});\nconsole.log(level.toString()); // @type 3, @spawn [0, 0, 0]\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flevelz-file%2Fjs-bindings","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flevelz-file%2Fjs-bindings","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flevelz-file%2Fjs-bindings/lists"}