Welcome to the official documentation for phenopackets-js
, a JavaScript library for creating and reading GA4GH Phenopackets. This library is generated from the official phenopacket-schema protobuf definitions.
Quick Start
Installation
npm install @berntpopp/phenopackets-js
Basic Example
const { Phenopacket, Individual } = require('@berntpopp/phenopackets-js');
// Create a new phenopacket
const phenopacket = new Phenopacket();
phenopacket.setId('example-id');
// Add an individual
const individual = new Individual();
individual.setId('patient-1');
individual.setSex(1); // FEMALE
phenopacket.setSubject(individual);
Documentation
Guides
- Installation - How to install the package
- Basic Usage - A quick example to get you started
- Development Guide - Information for developers
- Working with Proto Files - Understanding proto files
- Using JSON Utilities - Working with JSON
- Testing Strategy - Testing your implementation
- Contributing - How to contribute
API Reference
Detailed API Documentation for all generated classes and utilities.
About Phenopackets
The Phenopacket Schema represents an open standard for sharing disease and phenotype information to improve our ability to understand, diagnose, and treat both rare and common diseases. Learn more at phenopackets.org and the GA4GH Phenopacket Schema repository.
License
This library is licensed under the MIT License. The underlying Phenopacket Schema is licensed under BSD-3-Clause by GA4GH.