2.2.4 • Published 8 months ago

react-ipynb-renderer-katex v2.2.4

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
8 months ago

React Ipynb Renderer

This is a library to easily draw ipynb in a React application.

npm version e2e workflow License downloads FOSSA Status

Theme

Please choose your favorite combination from the multiple themes available for Jupyter and syntax highlighting.

There are several options for each, allowing you to find the perfect match for your preference.

solarizedl and duotone forest themesmonokai and xonokai themes
solarizedlmonokai

As for jupyter themes, you may use your own customized CSS. You do not necessarily have to use the prepared jupyter theme.

Formula renderer

You can choose Mathjax or Katex for rendering formulas.

Normally I would recommend choosing react-ipynb-renderer which uses Mathjax. react-ipynb-renderer-katex is a bit lighter than the mathjax version.

MathjaxKatex
NPMNPM
CodeSandboxCodeSandbox

These will be released at the same time, so the versions will be the same. Even if only one of them has been changed.

Install

$ npm install --save react-ipynb-renderer

or

$ npm install --save react-ipynb-renderer-katex

Usage

Just pass an ipynb json object to IpynbRenderer component.

Simplest example

Using react-ipynb-renderer

import { IpynbRenderer } from "react-ipynb-renderer";

// Jupyter theme
import "react-ipynb-renderer/dist/styles/monokai.css";
// import ipynb file as json
import ipynb from "./test.ipynb";

export const Component = () => {
  return (
    <IpynbRenderer ipynb={ipynb} />
  );
};

Using react-ipynb-renderer-katex

import { IpynbRenderer } from "react-ipynb-renderer-katex";

// Formula renderer for katex
import 'katex/dist/katex.min.css';

// Jupyter theme
import "react-ipynb-renderer-katex/dist/styles/monokai.css";
// import ipynb file as json
import ipynb from "./test.ipynb";

export const Component = () => {
  return (
    <IpynbRenderer ipynb={ipynb} />
  );
};

Links

License

FOSSA Status

2.2.4

8 months ago

2.2.3

10 months ago

2.2.4-1

10 months ago

2.2.4-0

10 months ago

2.2.2

10 months ago

2.2.2-1

10 months ago

2.2.2-0

10 months ago

2.2.0-rc.2

1 year ago

2.2.0-rc.0

1 year ago

2.2.0-rc.1

1 year ago

2.2.0-rc.6

1 year ago

2.2.0-rc.4

1 year ago

2.2.0-rc.5

1 year ago

2.2.1

1 year ago

2.2.0

1 year ago

2.2.0-alpha.0

1 year ago

2.2.1-rc.0

1 year ago

2.1.4

1 year ago

2.1.3

2 years ago

2.1.3-0

2 years ago

2.1.2

2 years ago

2.1.1

2 years ago

2.1.1-0

2 years ago

2.1.2-0

2 years ago

2.1.0

2 years ago

1.2.0

3 years ago

1.0.2

3 years ago

1.1.0

3 years ago

1.2.0-1

3 years ago

1.2.0-0

3 years ago

2.0.0-rc.0

3 years ago

1.0.3-1

3 years ago

1.0.3-0

3 years ago

1.0.3

3 years ago

2.0.1

3 years ago

2.0.0

3 years ago

1.0.1

3 years ago

1.0.1-4

3 years ago

1.0.1-3

3 years ago

1.0.1-2

3 years ago

1.0.1-0

3 years ago

1.0.0

3 years ago

1.0.0-alpha.0

3 years ago