Awesome
Unison Local UI
This is the UI you see when you type ui
into ucm
.
Running Development Server
🔔 You should only need to run the UI development server if you're contributing to the UI. If you just want to run the UI to see your Unison codebase, it should either come pre-installed with
ucm
or if you built from source it can be downloaded with a script:./dev-ui-install.hs
from theunison
repository (Running Unison).
-
Start
ucm
(the executable isunison
instead ofucm
if you built the unison repository from source) in headless mode:ucm headless
, and copy the API URL (this URL is uniquely generated byucm
at start-up) from theucm
start-up output (ucm
also outputs a UI URL, but this isn't used when developing for the UI/running the UI from this repository). -
Make sure the latest dependencies are installed with by running
npm install
followed bynpm run ui-core-install
. -
Start the dev server with:
API_URL="<API URL FROM UCM>" npm start
-
Visit
http://localhost:1234
in a browser.
💡 Set the environment variable
ELM_DEBUG=1
before starting the dev server to enable Elm's time-travelling debugger.
Dependencies
This depends on the ui-core package via elm-git-install. That package includes both the Unison design system, and a core set of components for working with and rendering Unison definitions and namespaces.
Bumping ui-core package
The UI Core dependency can be updated to its latest version with this command:
npm run ui-core-update
To install a specific sha:
npm run ui-core-install -- [SOME_UI_CORE_SHA]