{"id":38054159,"url":"https://github.com/sbgn/libsbgn.js","last_synced_at":"2026-01-16T20:21:41.508Z","repository":{"id":57290128,"uuid":"89239004","full_name":"sbgn/libsbgn.js","owner":"sbgn","description":"Parsing and writing SBGN-ML files in javascript","archived":false,"fork":false,"pushed_at":"2025-10-22T16:40:18.000Z","size":34520,"stargazers_count":3,"open_issues_count":5,"forks_count":3,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-10-22T18:30:21.747Z","etag":null,"topics":["bioinformatics","sbgn","sbgnml","systems-biology","xml"],"latest_commit_sha":null,"homepage":"https://sbgn.github.io/libsbgn.js/","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/sbgn.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2017-04-24T12:44:00.000Z","updated_at":"2024-07-08T15:44:54.000Z","dependencies_parsed_at":"2025-10-22T18:19:03.079Z","dependency_job_id":"cdf9b677-2d7e-4545-85dd-a3c95843f928","html_url":"https://github.com/sbgn/libsbgn.js","commit_stats":null,"previous_names":["eisbm/libsbgn.js"],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/sbgn/libsbgn.js","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbgn%2Flibsbgn.js","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbgn%2Flibsbgn.js/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbgn%2Flibsbgn.js/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbgn%2Flibsbgn.js/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sbgn","download_url":"https://codeload.github.com/sbgn/libsbgn.js/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sbgn%2Flibsbgn.js/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28482267,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-16T11:59:17.896Z","status":"ssl_error","status_checked_at":"2026-01-16T11:55:55.838Z","response_time":107,"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":["bioinformatics","sbgn","sbgnml","systems-biology","xml"],"created_at":"2026-01-16T20:21:36.984Z","updated_at":"2026-01-16T20:21:41.497Z","avatar_url":"https://github.com/sbgn.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# libsbgn.js\n\n[![npm](https://img.shields.io/npm/v/libsbgn.js.svg)](https://www.npmjs.com/package/libsbgn.js)\n[![Build Status](https://travis-ci.org/sbgn/libsbgn.js.svg?branch=master)](https://travis-ci.org/sbgn/libsbgn.js)\n\nDocumentation under construction.\n\nAPI doc is located [here](https://sbgn.github.io/libsbgn.js/).\nMore detailed documentation can be found in the wiki.\n\n## 1. Installation\n\n```\nnpm install libsbgn.js\n```\n\nRun test:\n```\nnpm test\n```\n\nGenerate API doc:\n```\nnpm run doc\n```\n\n## 2. Quick example\n\n```javascript\nvar libsbgn = require('libsbgn.js');\n\nvar sbgn = new libsbgn.Sbgn({xmlns: 'http://sbgn.org/libsbgn/0.3'});\n\nvar map = new libsbgn.Map({id: 'mymap', language: 'process description'});\nsbgn.addMap(map);\n\nvar glyph1 = new libsbgn.Glyph({id: 'glyph1', class_: 'macromolecule'});\nglyph1.setLabel(new libsbgn.Label({text: 'entity A'}));\nglyph1.setBbox(new libsbgn.Bbox({x: 0, y: 0, w:10, h:10}));\nmap.addGlyph(glyph1);\n\nvar glyph2 = new libsbgn.Glyph({id: 'glyph2', class_: 'macromolecule'});\nglyph2.setLabel(new libsbgn.Label({text: 'entity B'}));\nglyph2.setBbox(new libsbgn.Bbox({x: 20, y: 0, w:10, h:10}));\nmap.addGlyph(glyph2);\n\nvar processGlyph = new libsbgn.Glyph({id: 'process1', class_: 'process'});\nprocessGlyph.setBbox(new libsbgn.Bbox({x: 10, y: 0, w:10, h:10}));\nmap.addGlyph(processGlyph);\n\nvar arc1 = new libsbgn.Arc({id:'arc1', class_:'consumption',\n\tsource:'glyph1', target:'process1'});\narc1.setStart(new libsbgn.Start({x:0, y:0}));\narc1.setEnd(new libsbgn.End({x:10, y:0}));\nmap.addArc(arc1);\n\nvar arc2 = new libsbgn.Arc({id:'arc2', class_:'production',\n\tsource:'process1', target:'glyph2'});\narc2.setStart(new libsbgn.Start({x:10, y:0}));\narc2.setEnd(new libsbgn.End({x:20, y:0}));\nmap.addArc(arc2);\n\nvar xmlString = sbgn.toXML();\n```\n\nxmlString contains the serialized raw XML, without any newline or indentation. A pretty version of xmlString would be:\n\n```xml\n\u003csbgn xmlns=\"http://sbgn.org/libsbgn/0.3\"\u003e\n\t\u003cmap id=\"mymap\" language=\"process description\"\u003e\n\t\t\u003cglyph id=\"glyph1\" class=\"macromolecule\"\u003e\n\t\t\t\u003clabel text=\"entity A\"/\u003e\n\t\t\t\u003cbbox x=\"0\" y=\"0\" w=\"10\" h=\"10\"/\u003e\n\t\t\u003c/glyph\u003e\n\t\t\u003cglyph id=\"glyph2\" class=\"macromolecule\"\u003e\n\t\t\t\u003clabel text=\"entity B\"/\u003e\n\t\t\t\u003cbbox x=\"20\" y=\"0\" w=\"10\" h=\"10\"/\u003e\n\t\t\u003c/glyph\u003e\n\t\t\u003cglyph id=\"process1\" class=\"process\"\u003e\n\t\t\t\u003cbbox x=\"10\" y=\"0\" w=\"10\" h=\"10\"/\u003e\n\t\t\u003c/glyph\u003e\n\n\t\t\u003carc id=\"arc1\" class=\"consumption\" source=\"glyph1\" target=\"process1\"\u003e\n\t\t\t\u003cstart x=\"0\" y=\"0\"/\u003e\n\t\t\t\u003cend x=\"10\" y=\"0\"/\u003e\n\t\t\u003c/arc\u003e\n\t\t\u003carc id=\"arc2\" class=\"production\" source=\"process1\" target=\"glyph2\"\u003e\n\t\t\t\u003cstart x=\"10\" y=\"0\"/\u003e\n\t\t\t\u003cend x=\"20\" y=\"0\"/\u003e\n\t\t\u003c/arc\u003e\n\t\u003c/map\u003e\n\u003c/sbgn\u003e\n```\n## 3.Schematron Validation Example \nPlease place templatelibsbgn.xslt file your project structure\n```javascript\nvar libsbgn = require('libsbgn.js');\n\nvar fs = require('file-system');\n\nvar file=fs.readFileSync('path-of-validated-file', 'utf8');\n\nvar errors = libsbgn.Sbgn.doValidation(file);\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsbgn%2Flibsbgn.js","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsbgn%2Flibsbgn.js","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsbgn%2Flibsbgn.js/lists"}