Reactium
  • Quick Start
  • Discuss
  • Approach
    • Architecture
    • DDD Introduction
    • Domain Model
  • Reactium App Foundation
    • Reactium Guides
      • Creating a Simple Single Page Web App (SPA)
      • Creating a Sassy Style Sheet
      • Reactium Core
      • Reactium + Actinium (APIs)
      • Reactium + REST
      • Plugin Module Guide
      • Animating React Routes
      • Reactium in Production
    • Reactium Domain Model
      • Basic Domain Model
      • Runtime Domain Model
      • Buildtime Domain Model
    • Reactium SDK
      • Reactium SDK Reference
    • Updating Reactium
  • Installing Foundations
    • Before You Install
    • Install Reactium
    • Install Actinium
  • Reactium API Foundation (Actinium)
    • Actinium Core
    • Setting up your User
    • Actinium SDK
      • Actinium SDK Reference
    • Actinium Domain Model
    • Extending
    • Updating
    • Live Query
  • Reactium Toolkit
    • Overview
    • Installation
    • Configuration
    • Customization
    • Creating Elements
      • Sidebar Elements
      • Toolbar Elements
      • Documentation Elements
    • Components
      • Sidebar
      • MenuLink
      • Element
      • Code
      • Markdown
      • Icon
    • Toolkit SDK
Powered by GitBook
On this page
  • Properties
  • Usage
  1. Reactium Toolkit
  2. Components

MenuLink

Sidebar Navigation Render Component

PreviousSidebarNextElement

Last updated 4 years ago

Properties

Property

Type

Description

children

Node

Element to render inside the component

Required: true

exact

Boolean

When determining the active state, use an exact match

Default: false

expanded

Boolean

Determines the default expanded state

Default: false

group

String

When rendering as a Child Link, the Top-Level ID to target

id

String

Unique ID of the component

Required: true

url

String

Wraps the children in an anchor tag

Any additional properties are passed to the MenuLink container element.

Usage

reactium-hooks.js
import Reactium from 'reactium-core/sdk';

Reactium.Plugin.register('ToolkitOverview').then(() => {
    if (!Reactium.Toolkit) return;

    Reactium.Hook.register(
        'plugin-ready',
        () => {
            const MenuLink = Reactium.Component.get('RTKMENULINK');

            Reactium.Toolkit.Sidebar.register('overview', {
                exact: true,
                url: '/toolkit',
                component: MenuLink,
                children: 'Overview',
                'aria-label': 'Overview',
                order: Reactium.Enums.priority.highest,
            });
        }
    );
});