Skip to content

0.3.0 (OCT 17, 2026)

Latest

Choose a tag to compare

@pearmini pearmini released this 17 Oct 23:09

genji-theme-vitepress

Support magic variables! A variable whose name starts and ends with $$ shows its current value inside the code that uses it, and updates as the value changes.

```js eval code=false
$$size$$ = Inputs.range([0, 300], { label: "size", value: 100, step: 1 });
```

```js eval
call(() => {
  const size = $$size$$;
  const div = document.createElement("div");
  div.style.width = size + "px";
  div.style.height = "50px";
  div.style.background = "black";
  return div;
});
```

genji-runtime

  • Support modern JavaScript syntax in code blocks, such as optional chaining (a?.b) and ??. Code blocks are now parsed with acorn instead of esprima.
  • Find dependencies between code blocks with scope analysis, so local variables, object keys and function parameters no longer create false dependencies.
  • Report errors from a rejected promise on every code block that depends on it, instead of running them with undefined.
  • Detect circular dependencies of any length. Code blocks that depend on a cycle show Depends on a circular dependency.

Some pages may behave differently after upgrading, because these fixes change which code blocks depend on each other.

What's Changed

Full Changelog: 0.2.8...0.3.0