
Company News
Socket Named Top Sales Organization by RepVue
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.
@weng-lab/genomebrowser
Advanced tools
A powerful, interactive React-based genome browser for visualizing genomic data. Built with TypeScript, Vite, and modern web technologies.
A powerful, interactive React-based genome browser for visualizing genomic data. Built with TypeScript, Vite, and modern web technologies.
npm install @weng-lab/genomebrowser
yarn add @weng-lab/genomebrowser
pnpm add @weng-lab/genomebrowser
import React from "react";
import { Browser, Track, InitialBrowserState, createBrowserStore, createTrackStore, BrowserStoreInstance } from "@weng-lab/genomebrowser";
function GenomeBrowserExample() {
// Define your tracks
const initialTracks: Track[] = [...];
// Configure initial browser state
const initialState: InitialBrowserState = {
domain: {
chromosome: "chr12",
start: 53360037,
end: 53400206,
},
marginWidth: 150,
trackWidth: 1350,
multiplier: 3, // a multiplier to fetch more data for smooth panning
};
// Create stores to hold browser data
const browserStore = createBrowserStore(initialState)
const trackStore = createTrackStore(initialTracks)
return (
<div style={{ width: "90%", margin: "0 auto" }}>
<h1>My Genome Browser</h1>
<DomainDisplay browserStore={browserStore} />
<Browser browserStore={browserStore} trackStore={trackStore} />
</div>
);
}
// Use the stores to access information
function DomainDisplay({browserStore} : {browserStore: BrowserStoreInstance}) {
// Zustand-like selectors for getting fields and functions
const domain = browserStore((state) => state.domain)
return (
<h1>{domain.chromosome}:{domain.start}-{domain.end}</h1>
)
}
const initialState: InitialBrowserState = {
domain: {
chromosome: "chr1",
start: 1000000,
end: 2000000,
},
marginWidth: 150, // Width of the track margins
trackWidth: 1350, // Width of the viewable track area
multiplier: 3, // Data fetching multiplier for smooth panning
highlights: [
// Optional: initial highlights
{
id: "highlight1",
color: "#ffaabb",
domain: { chromosome: "chr1", start: 1500000, end: 1600000 },
},
],
};
Display continuous signal data (e.g., ChIP-seq, RNA-seq signals).
{
id: "signal",
title: "Signal Data",
trackType: TrackType.BigWig,
displayMode: DisplayMode.Full, // Multiple display modes supported
height: 100,
color: "#3498db",
url: "https://example.com/signal.bw",
}
Display discrete genomic regions (e.g., peaks, annotations).
{
id: "peaks",
title: "Peak Calls",
trackType: TrackType.BigBed,
displayMode: DisplayMode.Dense,
height: 20,
color: "#e74c3c",
url: "https://example.com/peaks.bigBed",
onClick: (rect) => console.log("Clicked:", rect), // Mouse interactivitiy
onHover: (rect) => console.log("Hovered:", rect),
tooltip: (rect) => <text>{rect.name}</text>, // Custom svg tooltips
}
Display multiple BigBed datasets in a single track.
{
id: "bulk-data",
title: "Multiple Datasets",
trackType: TrackType.BulkBed,
displayMode: DisplayMode.Full,
height: 40,
gap: 2, // Gap between datasets
color: "#9b59b6",
datasets: [
{ name: "Dataset 1", url: "https://example.com/data1.bigBed" },
{ name: "Dataset 2", url: "https://example.com/data2.bigBed" },
],
}
Display gene annotations and transcripts.
{
id: "genes",
title: "Gene Annotations",
trackType: TrackType.Transcript,
displayMode: DisplayMode.Squish,
height: 50,
color: "#2ecc71",
assembly: "GRCh38", // "mm10" also supported
version: 47, // GENCODE version
}
Explore our comprehensive Storybook documentation for detailed information about additional track types and their configuration options.
# Install dependencies
npm install
# Start development server
npm run dev
# Run Storybook for component development
npm run storybook
# Build for production
npm run build
# Run linting
npm run lint
MIT License - see LICENSE file for details.
For questions and support, please open an issue on GitHub.
FAQs
A powerful, interactive React-based genome browser for visualizing genomic data. Built with TypeScript, Vite, and modern web technologies.
We found that @weng-lab/genomebrowser demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 6 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Company News
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.

Security News
NIST will stop enriching most CVEs under a new risk-based model, narrowing the NVD's scope as vulnerability submissions continue to surge.

Company News
/Security News
Socket is an initial recipient of OpenAI's Cybersecurity Grant Program, which commits $10M in API credits to defenders securing open source software.