https://github.com/bencode/jupyterlite-clojure-kernel
A Clojure Kernel for JupyterLite.
https://github.com/bencode/jupyterlite-clojure-kernel
Last synced: about 2 months ago
JSON representation
A Clojure Kernel for JupyterLite.
- Host: GitHub
- URL: https://github.com/bencode/jupyterlite-clojure-kernel
- Owner: bencode
- License: mit
- Created: 2024-11-19T17:40:40.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-12-27T13:14:53.000Z (about 1 year ago)
- Last Synced: 2025-10-10T12:28:18.000Z (6 months ago)
- Language: TypeScript
- Size: 62.5 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# JupyterLite Clojure Kernel
A Clojure kernel for JupyterLite powered by [sci](https://github.com/babashka/sci) —— Small Clojure Interpreter, enabling Clojure code execution directly in the browser.
## Eamples
- [Using Clojure in JupyterLite](https://www.qijun.io/notebooks/index.html?path=using-clojure-in-jupyterlite.ipynb)
## Features
- Browser-based Clojure REPL
- No server-side dependencies
- Core Clojure functions support
## Installation
```bash
pip install jupyterlite-clojure-kernel-canary
```
## Usage
1. Install JupyterLite
2. Add the Clojure kernel
3. Create a new notebook with Clojure kernel
## Development
### 1. build sci-npm
``` shell
cd packages/sci-npm
pnpm install
pnpm build
```
### 2. build kernel
``` shell
cd packages/jupyterlite-clojure-kernel
pnpm install
# pnpm watch # for develop
pnpm build
```
### 3. serve jupyterlite
``` shell
# cd $projectroot
pip install jupyterlab jupyterlite
t
pnpm install
pnpm dev:install
pnpm dev:build
python -m http.server --directory _output
```
## Examples
```clojure
;; Basic calculations
(+ 1 2 3)
;; Define functions
(defn square [x] (* x x))
;; Data structures
(def data {:name "Alice" :scores [98 92 85]})
```
## License
MIT