Installing AdapTable for AG Grid

View as Markdown

Summary

  • AdapTable for AG Grid is installed from a public npm registry
  • This is the TypeScript (framework-agnostic) package
  • Requires AG Grid Enterprise 36.2 or later
  • AdapTable supports ESM (preferred) and CJS formats

This page describes how to install the TypeScript (framework-agnostic) version of AdapTable.

Find Out More

Public npm Registry

AdapTable is installed from a public npm Registry.

Developer Guide

Installing AdapTable

To install AdapTable follow these steps:

Caution

These steps assume you are using ESM format and so they reference the ESM packages; see below to learn how to use CommonJS format

Terminal
npm install @adaptabletools/adaptable
1
Install AdapTable from npm

Use the standard npm install command.

Terminal
npm install @adaptabletools/adaptable-plugin-master-detail-aggrid
2
Install any AdapTable Plugins that are required

For example to use Master-Detail functionality add:

Note

Plugins reduce download size by placing less frequently used functionality outside the main download

Terminal
npm install ag-grid-enterprise
3
Install AG Grid Enterprise

Install the AG Grid Enterprise package (v.36.2 or later)

Note

  • AG Grid 36 also installs ag-stack - you do not normally need to add it yourself
  • If npm reports a missing peer, install ag-stack@>=36.2.0 and keep a single copy in the project
Terminal
npm install ag-charts-enterprise
4
Install AG Grid Charting (optional)

If you plan to use AG Grid Charts, or AdapTable's Sparkline Columns, additionally install the AG Charts package.

const adaptableOptions: AdaptableOptions = {
  licenseKey: '<ADAPTABLE_LICENSE_KEY_HERE>',
};
5
Set the AdapTable License

This is done via the licenseKey property in Adaptable Options

ESM and CJS formats

AdapTable ships with support for both ESM and CJS formats, using 2 parallel sets of packages.

Caution

AdapTable strongly recommends using ESM wherever possible

  • If using ESM, install the "normal" AdapTable packages (e.g. @adaptabletools/adaptable)
  • If using CommonJS, install the CJS packages (e.g. @adaptabletools/adaptable-cjs)

Note

All the CJS packages use the name of the ESM package plus the -cjs suffix

ESM PackageCJS Package
@adaptabletools/adaptable@adaptabletools/adaptable-cjs
@adaptabletools/adaptable-plugin-interopio@adaptabletools/adaptable-plugin-interopio-cjs
@adaptabletools/adaptable-plugin-ipushpull@adaptabletools/adaptable-plugin-ipushpull-cjs
@adaptabletools/adaptable-plugin-master-detail-aggrid@adaptabletools/adaptable-plugin-master-detail-aggrid-cjs
@adaptabletools/adaptable-plugin-openfin@adaptabletools/adaptable-plugin-openfin-cjs

Find Out More

See Using AG Grid Modules & Packages for more detailed information

AdapTable Resources