First steps

Key principles and essential steps for building a new application with Onyx.

This guide assumes you have completed the basic setup. If not, follow the installation guide first.

Copy link to headline:Layout

We strongly recommend using the app and page layout components to structure your application. They provide consistent layout structures, correct scroll container management, and system-level components.

  1. App layout

    The app layout is placed once at the root of your application. It serves as the shell for global navigation and main content, while hosting system-level components like toasts and notifications.

  2. Page layout

    Use page layout on every page to ensure standardized spacing and scroll containers. It provides dedicated slots for sidebars, footers, and page content.

Copy link to headline:Grid settings

Configure your application grid by defining a maximum width and alignment early on.

On wide screens, stretching content across the full width impairs readability. We recommend capping content at 1920px (the lg breakpoint) with center alignment. Apply these utility classes to your root component:

For all options, see the: