AG Grid Modules
Summary
- AG Grid provides functionality via Modules
- These are available either as a Bundle, or individually selected
- Some AG Grid Modules are mandatory in AdapTable, while others are required for certain features to work
AG Grid provides its functionality through a series of AG Grid Modules.
This is available in 2 forms:
- as a bundle (
AllEnterpriseModule) - as specific modules (in order to reduce download size)
Caution
AG Grid modules must be registered regardless whether you use ESM (standard) or CommonJS formats
AllEnterpriseModule Bundle
AG Grid provides a comprehensive AllEnterpriseModule bundle.
This is the easiest option as it contains both Community and Enterprise modules, including everything AdapTable needs for core functionality.
Caution
- Charts and Sparklines are not included in the bundle (nor is
ValidationModule— see Development Validations) - Register
AllEnterpriseModule.with(AgChartsEnterpriseModule)(fromag-charts-enterprise) if you use AG Grid Charts or Sparkline Styled Columns
Selecting Modules
Alternatively, you can register only the modules you want to use in your application.
This allows you to reduce the bundle size of your application (but requires more considered thought).
Hint
AG Grid provides a useful Module Selector to see what is required for your use case from an AG Grid perspective
AdapTable leverages AG Grid Modules for much of its functionality - both core and feature-specific.
As a result, it is useful to divide the AG Grid Modules into 3 groups:
| Group | Description |
|---|---|
| Mandatory | Without these AG Grid Modules, AdapTable simply won't work, so they must be supplied |
| Per-Feature | AG Grid Modules which are needed on a per-feature basis |
| Avoid | Using these AG Grid Modules can cause issues, so should be avoided |
Mandatory Modules
There are some Modules which must be registered for AdapTable to work.
Caution
Without these modules, AdapTable will either not start or will display significant errors at start-up
You must provide the relevant Module, and associated API, for the AG Grid RowModel you are using.
Client-Side Row Model
For the (default) Client Side Row Model you need to provide:
ClientSideRowModelApiModule
Note
The Client-Side Row Model is part of the grid core, so ClientSideRowModelModule is not required.
Server-Side Row Model
If you are using the Server-Side Row Model, you need to provide
ServerSideRowModelModuleServerSideRowModelApiModule
Viewport Row Model
If you are using AG Grid's Viewport Row Model, you need to provide:
ViewportRowModelModule
Infinite Row Model
Caution
AdapTable does not support AG Grid's Infinite Row Model
Additionally there are a number of AG Grid API Modules that AdapTable uses to tie everything together:
All Row Models
There are some Modules that need to be provided irrespective of the Row Model being used.
Note
All of these are mandatory and must be provided for a seamless and error-free user experience
CellStyleModuleColumnMenuModuleContextMenuModuleCustomFilterModuleExternalFilterModuleGridStateModuleGroupFilterModuleRowGroupingModuleRowStyleModuleCellApiModuleColumnApiModuleEventApiModuleRenderApiModuleRowApiModuleScrollApiModule
Per-Feature Modules
Additional AG Grid Modules must be registered to enable using their specific features in AdapTable.
Caution
Without these modules, certain functionalities in AdapTable will be limited or unavailable
Here is the full list of AG Grid Modules which AdapTable requires (on a per-feature basis):
| AG Grid Module | Where Used |
|---|---|
CellSelectionModule | Cell Summary, Plus Minus and Selecting Data |
ColumnAutoSizeModule | Layout Auto-Sizing |
CsvExportModule | CSV Export Report Format |
ExcelExportModule | Excel and VisualExcel Report Formats |
FindModule | Quick Search |
NotesModule | Notes |
IntegratedChartsModule | If using AG Grid's Charts functionality |
MasterDetailModule | By the Master Detail Plugin |
PinnedRowModule | Row Summaries |
PivotModule | Pivoting |
QuickFilterModule | Running Quick Search as Filter |
RichSelectModule | If using Select Editors |
RowSelectionModule | Needed for Selecting via Grid Api |
SideBarModule | Adaptable ToolPanel |
SparklinesModule | Sparkline Styled Column |
StatusBarModule | Adaptable Status Bar |
TextEditorModule | Used for editing (all columns) |
TooltipModule | Calculated Column & many Styled Columns |
TreeDataModule | If using the Tree Grid |
Note
IntegratedChartsModule and SparklinesModule also require AgChartsEnterpriseModule from ag-charts-enterprise (the same module passed to AllEnterpriseModule.with(...))
To Be Avoided Modules
Two AG Grid Modules should not be registered with AdapTable.
SetFilterModule
AG Grid provides a SetFilterModule - which it uses in its filtering.
However AdapTable provides its filtering independently.
Registering this module can cause AG Grid to treat Set Filter as the default filter type, overriding AdapTable's filter implementation.
Caution
We strongly recommend not importing or registering the SetFilterModule
Hint
- When AdapTable filtering is enabled (the default), AdapTable already sets
suppressSetFilterByDefaultto true - If you must register
SetFilterModule, keep that Grid Option set to true
CalculatedColumnsModule
AG Grid also provides a CalculatedColumnsModule.
That is not the same as AdapTable Calculated Columns (which are evaluated by AdapTableQL and stored in Adaptable State).
Caution
- Do not register
CalculatedColumnsModuleif you are using AdapTable Calculated Columns - Importing both gives users two ways to create calculated columns and is likely to cause confusion
Development Validations
AG Grid's ValidationModule is not included in AllEnterpriseModule.
It is useful in development - provides fuller console messages and on-grid overlay of configuration problems.
However it should not be shipped in production.
Hint
- Register
ValidationModulein development only - Alternatively call
enableDevValidations()fromag-grid-communitybefore the grid is created
Appendix: All AG Grid Modules
This is the full list of AG Grid Modules (listed in the same order as AG Grid does).
We indicate whether it is required, or used by AdapTable, and if so, where:
| AG Grid Module | Purpose | AdapTable Behaviour |
|---|---|---|
ValidationModule | Validation (Dev Mode) | Recommended in development only |
ColumnAutoSizeModule | Column Auto-Sizing | Auto Sizing Layouts |
ColumnHoverModule | Column Hovering | n/a |
AutoGenerateColumnsModule | Auto-Generate Columns | n/a |
FileInputOverlayModule | File Input Overlay | n/a |
CalculatedColumnsModule | AG Grid Calculated Columns | Not AdapTable's feature — don't provide |
ColumnHeaderEditModule | Editable Header Name | Not used — Layouts provide Column Headers |
PinnedRowModule | Pinning Rows | Row Summaries |
RowAutoHeightModule | Auto Row Height | n/a |
RowStyleModule | Styling Rows | Mandatory |
PaginationModule | Row Pagination | n/a |
PaginationPageNumbersModule | Page Number Navigation | n/a |
RowDragModule | Row Dragging | n/a |
RowNumbersModule | Numbering Rows | n/a |
CellSpanModule | Spanning Cells | n/a |
CellStyleModule | Styling Cells | Mandatory |
HighlightChangesModule | Highlighting Changes | n/a |
TooltipModule | Tooltips | In Calculated Columns & Styled Columns |
FormulaModule | Formulas | n/a |
FindModule | Find | Quick Search |
NotesModule | Cell Notes | Notes |
TextFilterModule | Text Filter | Ignored by AdapTable |
NumberFilterModule | Number Filter | Ignored by AdapTable |
DateFilterModule | Date Filter | Ignored by AdapTable |
BigIntFilterModule | BigInt Filter | Ignored by AdapTable |
SetFilterModule | Set Filter | Can break AdapTable - do not provide |
MultiFilterModule | Multi Filter | Ignored by AdapTable |
CustomFilterModule | Custom Filter | Mandatory |
AdvancedFilterModule | Advanced Filter | Ignored by AdapTable |
ExternalFilterModule | External Filter | Mandatory |
QuickFilterModule | Quick Filter | Quick Search (Filter Results) |
RowSelectionModule | Row Selection | Needed for Row Select Api methods |
CellSelectionModule | Cell Selection | Needed for Cell Select Api methods |
TextEditorModule | Text Editor | Used for editing (all columns) |
LargeTextEditorModule | Large Text Editor | n/a |
SelectEditorModule | Select Editor | n/a |
RichSelectModule | Rich Select Editor | Used for Adaptable Select Cell Edits |
NumberEditorModule | Number Editor | n/a |
DateEditorModule | Date Editor | n/a |
CheckboxEditorModule | Checkbox Editor | n/a |
CustomEditorModule | Custom Cell Editor | n/a |
UndoRedoEditModule | Undo / Redo Edits | n/a |
BatchEditModule | Batch Edit | n/a |
LocaleModule | Localisation | n/a |
RowGroupingModule | Row Grouping | Mandatory |
RowGroupingPanelModule | Row Grouping Panel | n/a |
GroupFilterModule | Group Filter | Mandatory |
RowGroupingEditModule | Editing Group Row Cells | n/a |
PivotModule | Pivoting | Pivot Layouts |
TreeDataModule | Tree Data | Tree Grids |
ShowValuesAsModule | Show Values As | n/a |
MasterDetailModule | Master Detail | Master Detail plugin |
SideBarModule | Side Bar | AdapTable Tool Panel |
ColumnsToolPanelModule | Columns Tool Panel | n/a |
FiltersToolPanelModule | Filters Tool Panel | n/a |
NewFiltersToolPanelModule | New Filters Tool Panel | n/a |
ColumnMenuModule | Column Menu | Mandatory |
ContextMenuModule | Context Menu | Mandatory |
StatusBarModule | Status Bar | AdapTable Status Panels |
ToolbarModule | Toolbar | n/a |
AiToolkitModule | AI Toolkit | n/a |
CsvExportModule | CSV Export | CSV Export Report Format |
ExcelExportModule | Excel Export | Excel Export Report Format |
PdfExportModule | PDF Export | n/a |
ClipboardModule | Clipboard | n/a |
DragAndDropModule | Drag & Drop | n/a |
ValueCacheModule | Value Cache | n/a |
AlignedGridsModule | Aligned Grids | n/a |
GridStateModule | Grid State | Mandatory |
ColumnApiModule | Column API | Mandatory |
RowApiModule | Row API | Mandatory |
CellApiModule | Cell API | Mandatory |
ScrollApiModule | Scrolling API | Mandatory |
RenderApiModule | Rendering API | Mandatory |
EventApiModule | Event API | Mandatory |
ClientSideRowModelApiModule | Client-Side Row Model API | Mandatory (if using Client-Side Row Model) |
ServerSideRowModelApiModule | Server-Side Row Model API | Mandatory (if using Server-Side Row Model) |
The Module Selector does not list Charts, Sparklines or Row Model modules. The extra ones AdapTable uses are:
| AG Grid Module | Purpose | AdapTable Behaviour |
|---|---|---|
IntegratedChartsModule | Integrated Charts | AG Grid Charts (requires AgChartsEnterpriseModule) |
SparklinesModule | Sparklines | Sparkline Styled Columns (requires AgChartsEnterpriseModule) |
ServerSideRowModelModule | Server-Side Row Model | Mandatory if using Server-Side Row Model |
ViewportRowModelModule | Viewport Row Model | Mandatory if using Viewport Row Model |
ClientSideRowModelModule | Client-Side Row Model | Not required (part of grid core) |