Build modules to reuse queries and components
Learn how to reuse groups of components and queries across apps.
A module is a reusable group of components and queries. You might use a module to reuse common components in multiple apps or split up common functionality into smaller parts. For example, you can use modules to:
- Create common search filters
- Build a navigation bar to use across all your apps
- Share forms between apps
- Break large, complex apps into smaller, more maintainable parts
Build a module
You can create a module from scratch, by cloning a module from an app, or by copying components to a module. Once you've created your module, you can define it further with inputs and outputs.
Create modules
To create a module, on your home page, select Create new > Module and give it a unique name. You can change the name any time in the App IDE.
After creating a module, assemble components using the same methods you would use to build an app.
Clone apps to modules
Cloning an app to a module copies the app's components and queries to a new module, leaving the app unchanged. To clone an app from a module, click on the App actions menu and select Clone to module.
Copy components to modules
To copy components to a module, select the components— + Click—to include and select Duplicate to module.
Add inputs
Inputs are data or queries that can be passed into your modules from apps or other modules. A module input can be either a data input or a query input.