Home

Awesome

pyQuirk

pypi

A Python widget for Quirk to be used in Jupyter notebooks, JupyterLab, and the IPython kernel.

Example

Getting Started

Installation

To install use pip (JupyterLab 3 recommended):

$ pip install pyQuirk

If you are wanting to use this with JupyterLab 2 or a classical Jupyter notebook install (i.e. not the one included with JupyterLab 3), then you can try following the development install instructions below, but YMMV.

Example

Take a look at example.ipynb for a simple example.

Otherwise, you can simply run:

from pyQuirk import Quirk
quirk = Quirk()
quirk

API

Quirk()

Development

For a development installation (requires Node.js and Yarn version 1),

$ git clone https://github.com/adgt/pyQuirk.git
$ cd pyQuirk
$ pip install -e .

If you are working with Jupyter notebook, then run these commands:

$ jupyter nbextension install --py --symlink --overwrite --sys-prefix pyQuirk
$ jupyter nbextension enable --py --sys-prefix pyQuirk

If you are working with JupyterLab 3, run the command:

$ jupyter labextension develop --overwrite pyQuirk

Then you need to rebuild the JS when you make a code change:

$ cd js
$ yarn run build

You then need to refresh the JupyterLab page when your javascript changes.

Project repository created with the widget-cookiecutter template