# Interactive REPL

> Evaluate JavaScript, TypeScript, Python and WebAssembly interactively and share values between them.

```bash
elide repl
```

`elide` with no arguments in a terminal also starts it. Languages: JavaScript, TypeScript, Python and WebAssembly.

<img src="https://elide.help/assets/demos/repl.gif" alt="One REPL session — JavaScript values used from Python" width="1107" height="691" loading="lazy" decoding="async" class="rounded-lg border border-border my-6 w-full" />

## Commands

| Command | Effect |
| --- | --- |
| `/js`, `/ts`, `/py`, `/wasm` | Switch language. With an argument, evaluate it once in that language. |
| `/lang NAME` | Switch language. |
| `/export NAME` | Share a value with the other languages. |
| `/import NAME` | Bind a shared value in the current language. |
| `/history [N]` | Show recent entries. |
| `/reset` | Delete saved history. |
| `/clear` | Clear the screen. |
| `/help` | List commands. |
| `/exit` | Leave the REPL. |

## Share values

```text
const x = 41
/export x
/py
/import x
print(x + 1)
```

```text
42
```

Sharing works without `--interop`.
