Test changes without publishing
Goal: see changes in the host EMR within seconds of saving a file, without touching the marketplace.
Prerequisites:
- A scaffolded app with manifest and bundle config.
- Logged in (
orion login). - A sandbox tenant configured — see First-time setup below if you've never run
orion devagainst this app.
First-time setup
If orion sandbox:status reports No sandbox configured, the CLI doesn't yet know which sandbox tenant to tunnel into. The full first-time tenant setup is covered in the tutorial; the abbreviated form below is enough to unblock this recipe.
Run:
orion config sandboxThe command prompts for your sandbox tenant URL — typically https://sandbox-<tenant>.orion.local for local development, or whatever sandbox-prefixed URL your Orion admin assigned. The CLI validates that the URL starts with https:// and contains sandbox- somewhere in it, then calls the sandbox to fetch the tenant UUID automatically. If that fetch fails, you'll be prompted to paste the UUID manually — it lives in the Orion admin panel under the tenant detail page.
The values land in your global CLI config (managed by Conf, not a checked-in file), so re-running this only matters when you switch sandbox targets.
Verify the result:
orion sandbox:statusYou should now see the sandbox URL, the configured app id, and a healthy status line. If the sandbox is unreachable, double-check the URL and that the host EMR sandbox is running.
Steps
Why not just publish? Each
orion publishconsumes a version slot, kicks off a marketplace review, and isn't reversible without admin help. Publish is for stable releases. For iteration, useorion dev.Start the dev server:
bashorion devThree things happen: Vite starts on
localhost:5173, the CLI opens a Cloudflare tunnel exposing it via HTTPS, and it registers the tunnel URL with your sandbox tenant. The host EMR's iframe pulls your bundle from the tunnel instead of the CDN.Open the host EMR's sandbox UI and navigate to a surface where your app is mounted — a patient sidebar if you have a widget, a route if you have a page. The iframe loads the live tunnel content. Save a file in your editor and HMR reloads inside the iframe.
Inspect manifest changes. If you change
orion-app.json, the CLI auto-restarts the dev server (it watches the manifest and re-registers with the sandbox). Code changes hot-reload through Vite as usual.Reset the sandbox between test runs if your manual interactions left data behind. Reseed from the Orion UI afterwards:
bashorion sandbox:resetCheck what's currently registered with the sandbox. The output shows the sandbox URL, health status, your configured app id, and (when registered) the dev URL the sandbox is pointing at:
bashorion sandbox:statusValidate locally before stepping up to publish. This runs everything
publishruns except the actual upload. Clean here usually means clean publish:bashorion validate
Verify
Edit a component file, save, and watch the host EMR iframe refresh within about a second. No publishing happened.