GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - root-project/jsroot: JavaScript ROOT

BranchesTags
Open more actions menu

Latest commit

 

History

15,729 Commits
15,729 Commits

Folders and files

NameName
Last commit message
Last commit date
.github
.github
 
 
build
build
 
 
demo
demo
 
 
docs
docs
 
 
files
files
 
 
fonts
fonts
 
 
img
img
 
 
libs
libs
 
 
modules
modules
 
 
scripts
scripts
 
 
server
server
 
 
.clang-format
.clang-format
 
 
.gitignore
.gitignore
 
 
LICENSE
LICENSE
 
 
api.htm
api.htm
 
 
changes.md
changes.md
 
 
eslint.config.js
eslint.config.js
 
 
examples.htm
examples.htm
 
 
index.htm
index.htm
 
 
package-lock.json
package-lock.json
 
 
package.json
package.json
 
 
readme.md
readme.md
 
 
types.d.ts
types.d.ts
 
 

Repository files navigation

JavaScript ROOT

JavaScript ROOT provides interactive ROOT-like graphics in the web browsers and in node.js. Data can be read and displayed from ROOT binary and JSON files. JSROOT implements user interface for THttpServer class.

Examples

Color draw for TH2 2-dimensional TTree::Draw with cut options Several variants of THStack drawing Drawing of TGeo model superimposed with tracks and hits

In web browser

...
   <body>
      <div id="drawing" style="position: relative; width: 800px; height: 600px;"></div>
   </body>
   <script type='module'>
      import { openFile, draw } from 'https://root.cern/js/latest/modules/main.mjs';
      let file = await openFile('https://root.cern/js/files/hsimple.root');
      let obj = await file.readObject('hpxpy;1');
      draw('drawing', obj, 'colz');
   </script>
...

In node.js

import { openFile, makeSVG } from 'jsroot';
import { writeFileSync } from 'fs';
let file = await openFile('https://root.cern/js/files/hsimple.root');
let obj = await file.readObject('hpxpy;1');
let svg = await makeSVG({ object: obj, option: 'lego2,pal50', width: 800, height: 600 });
writeFileSync('lego2.svg', svg);

More examples

Supported classes/options

API examples

Install

npm install jsroot

For 3D rendering jsroot uses gl package which may have problems during installation. To use jsroot without gl one can omit development packages:

npm install jsroot --omit=dev

Documentation

Tutorial

THttpServer

Changelog

Reference API

Links

https://root.cern/js/

https://jsroot.gsi.de

About

JavaScript ROOT

Resources

Readme
MIT license
Activity
Custom properties

Stars

216 stars

Watchers

16 watching

Forks

90 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.