Omnira Docs v1.0.0

Quick start: source files

The source files let you change a colour, a menu, a phone number or a whole section once and rebuild every page automatically. You'll run three short commands; you don't need to know how to program.

1. Install Node.js (once)#

Download the “LTS” version from nodejs.org and install it like any other program. To check it worked, open a terminal (on Windows: Command Prompt or PowerShell; on macOS: Terminal) and type:

BASH
node -v

You should see a version number such as v20.11.0. Anything from 18 upwards is fine.

2. Install the template's tools (once)#

In the terminal, go to the source folder and install. The easiest way to “go to” a folder: type cd followed by a space, drag the source folder onto the terminal window, and press Enter.

BASH
cd path/to/Omnira/source
npm install

This downloads the build tools into a node_modules folder. It takes a minute and only needs doing once.

3. Start the live preview#

BASH
npm run dev

Open http://localhost:3000 in your browser. Leave the terminal open: every time you save a file in src/, the pages rebuild. Refresh the browser to see the change. Press Ctrl + C in the terminal to stop.

4. Make your changes#

Everything you edit is in source/src/:

To change…EditGuide
Business name, logo, phone, email, address, social linkssrc/config/site.jsonName, logo and contact details
A demo's colours, fonts, menu, header and footersrc/demos/<demo>/demo.jsonColours and fonts, Header and menu
The content of a pagesrc/demos/<demo>/pages/<page>.jsonPages and sections
Rooms, courses, products, team members, blog posts…src/demos/<demo>/data.jsonData and detail pages
Stylessrc/scss/Styles (SCSS)

5. Build your finished website#

When you're happy, build just the demo you're using as a standalone website:

BASH
npm run site -- restaurant

This creates a site folder with the restaurant pages at the top level, all the assets they need, and no demo or colour switcher. Upload the contents of site/ to your hosting. See Publishing your site.

To rebuild all demos instead (for example to keep the overview page), run npm run build; the result is in dist/.

Made a typo? If a JSON file has a mistake (a missing comma or quote), the terminal shows the file name and the line, and the other pages keep working. See Troubleshooting.