Skip to content

Lens (browser extension)

Tools

Your Arc app, inspectable in the browser

You’re testing an Arc app in the browser and you want to fire a command with a specific payload, or check what a query returns for a different tenant — without writing a throwaway page. Lens is a browser extension that does exactly that: it detects the running Arc app in your current tab, lets you browse its commands and queries by namespace, run them with a structured form, and switch the active user and tenant on the fly.

Lens opens as a popup with four tabs. When the current tab is a running Arc application, it detects it automatically and lights up the command and query browsers.

Under the hood it’s a Manifest V3 extension built with React, Vite, and PrimeReact — the same UI stack as Components — and it talks to the Arc backend’s introspection endpoints to discover the command and query catalog.

Until Lens reaches the stores, build it from source and load it unpacked. The source is at github.com/Cratis/Lens.

  1. Clone the repo, then from the Source folder install and build:

    Terminal window
    cd Source
    yarn
    yarn build

    This produces Source/dist/ (including manifest.json).

  2. Open chrome://extensions, enable Developer mode, choose Load unpacked, and select the Source/dist folder. Lens appears as Lens – Cratis Developer Tools.

  3. Navigate to your running Arc app, open the Lens popup once so it detects the app, then open its settings, confirm the Tenant Header Name, and save.

For an active edit loop, run yarn dev to rebuild on change, and reload the extension from chrome://extensions after each rebuild.