Combining multiple Bryntum products

Thin packages overview

Bryntum's products share the same data model and can be combined to provide different views of the underlying data.

When combining multiple Bryntum products in a single application using Ionic + Angular, you should use thin npm packages. This avoids runtime errors and also reduces the amount of code and CSS that has to be downloaded.

The main difference between thin packages and regular packages is that thin only contain product specific code and styling, while regular contain code and styling for all underlying products (for example Scheduler includes Scheduler + Grid + Core). Thin packages are valid for building a single product application.

It is not possible to import several regular (non-thin) Bryntum npm packages like @bryntum/grid and @bryntum/calendar in one application. Doing this will lead to a runtime console error:

The Bryntum Grid bundle was loaded multiple times by the application.

Do not mix regular (e.g., @bryntum/grid) and thin (e.g., @bryntum/grid-thin) packages in the same project. If using thin packages, remove regular ones and follow this guide to install all required dependencies.

Thin packages list

Bryntum's npm repository contains thin packages for combining multiple Bryntum products in one application.

Thin limited trial library packages:

PackagePurpose
@bryntum/core-thin-trialBryntum Core data and UI trial components package
@bryntum/grid-thin-trialBryntum Grid trial components package
@bryntum/scheduler-thin-trialBryntum Scheduler trial components package
@bryntum/schedulerpro-thin-trialBryntum Scheduler Pro trial components package
@bryntum/gantt-thin-trialBryntum Gantt trial components package
@bryntum/calendar-thin-trialBryntum Calendar trial components package
@bryntum/taskboard-thin-trialBryntum TaskBoard trial components package
@bryntum/engine-thin-trialBryntum Scheduling engine trial components package

To use framework wrappers, trial packages listed above require aliasing the @bryntum/-thin-trial package as @bryntum/-thin during installation, as shown below. Once installed, the provided app code samples can be used without modification

Example for @bryntum/grid-thin-trial package:

npm install @bryntum/grid-thin@npm:@bryntum/[email protected]

Alternatively, you can directly add entries to the "dependencies" section of the package.json project file as follows:

"dependencies": {
  "@bryntum/grid-thin": "npm:@bryntum/[email protected]",
}

Thin licensed library packages:

PackagePurpose
@bryntum/core-thinBryntum Core data and UI components package
@bryntum/grid-thinBryntum Grid components package
@bryntum/scheduler-thinBryntum Scheduler components package
@bryntum/schedulerpro-thinBryntum Scheduler Pro components package
@bryntum/gantt-thinBryntum Gantt components package
@bryntum/calendar-thinBryntum Calendar components package
@bryntum/taskboard-thinBryntum TaskBoard components package
@bryntum/engine-thinBryntum Scheduling engine components package

Thin Angular wrapper packages:

PackagePurpose
@bryntum/core-angular-thinBryntum Core UI widgets Angular wrappers package
@bryntum/grid-angular-thinBryntum Grid Angular wrapper package
@bryntum/scheduler-angular-thinBryntum Scheduler Angular wrapper package
@bryntum/schedulerpro-angular-thinBryntum Scheduler Pro Angular wrapper package
@bryntum/gantt-angular-thinBryntum Gantt Angular wrapper package
@bryntum/calendar-angular-thinBryntum Calendar Angular wrapper package
@bryntum/taskboard-angular-thinBryntum TaskBoard Angular wrapper package

Package dependencies

Each package contains code related to the specific product only and requires installing a dependency packages for all underlying products. This is not done automatically to give you full control over the installed packages.

List of required dependencies used in package.json for Angular application:

@bryntum/core-angular-thin is listed among the available framework wrapper packages, but you only need to install it if you use Bryntum Core UI widgets in your app (e.g., BryntumButton, BryntumCombo etc.). It's not needed otherwise.
However, you should always install all API packages as they are required for the proper functioning.

Please note that you need an active license for each product to use it in the UI.

API packages:

{
  "dependencies": {
    "@bryntum/core-thin": "7.2.0-alpha-1",
    "@bryntum/grid-thin": "7.2.0-alpha-1"
  }
}

Framework wrapper packages:

{
  "dependencies": {
    "@bryntum/core-angular-thin": "7.2.0-alpha-1",
    "@bryntum/grid-angular-thin": "7.2.0-alpha-1"
  }
}

Modules configuration

Importing package module for Ionic + Angular application app.module.ts:

import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';

import { BryntumCoreModule } from '@bryntum/core-angular-thin';
import { BryntumGridModule } from '@bryntum/grid-angular-thin';

import { AppComponent } from './app.component';

@NgModule({
    declarations : [
        AppComponent
    ],
    imports      : [
        BrowserModule,
        BryntumCoreModule,
        BryntumGridModule
    ],
    providers    : [],
    bootstrap    : [AppComponent]
})
export class AppModule {}

Product configuration

Importing product configuration for Angular application app.config.tsx:

import { BryntumGridProps } from '@bryntum/grid-angular-thin';

const gridProps : BryntumGridProps = {
    // Grid configuration
};

Product styling

List of required styles for Ionic + Angular application app.component.scss:

SCSS/CSS:

/* FontAwesome is used for icons */
@import '@bryntum/core-thin/fontawesome/css/fontawesome.css';
@import "@bryntum/core-thin/fontawesome/css/solid.css";
/* Structural CSS */
@import '@bryntum/core-thin/core.css';
@import '@bryntum/grid-thin/grid.css';
/* Theme */
@import '@bryntum/core-thin/material3-light.css';

If you import styles from *.scss files, please ensure that fonts from @bryntum/core-thin are copied to assets.

Add this to angular.json file:

"assets": [
  {
    "glob": "**/*",
    "input": "node_modules/@bryntum/core-thin/fonts",
    "output": "assets/fonts"
  },
  ...
],

These setup is also required for styling.

Add to app.component.scss before importing component styles:

// This is required to setup font locations for Angular SCSS preprocessor
$fa-font-path  : '../../fonts';
$roboto-font-path : '../../../fonts';

Product template

Example of configuring product template for Ionic + Angular application app.component.html:

<bryntum-grid
    #grid
    ...
></bryntum-grid>