Bringing the data visualization power of Chartbrew directly to the Strapi dashboard. Visualize your collection data with multi-dashboard support.
This is the official Chartbrew plugin for Strapi. Chartbrew is an open-source web application that can connect directly to Strapi and other data sources and use the data to create beautiful charts. It features a chart builder, editable dashboards, embedable charts, query & requests editor, and team capabilities.
Note This plugin is compatible with Strapi v5.
If you are using Strapi v4, check out the strapi-v4 branch of this repository.
To use this plugin, you will need to have a Chartbrew account, or self-host the platform.
Chartbrew is offered as a managed service in exchange for a monthly subscription. This is the fastest way to get started and create visualizations in Strapi. Follow the instructions below to get started:
Chartbrew is 100% open-source and can be self-hosted. Check out some links to get you started:
Navigate to the root of your Strapi folder and run the installation commands below.
With npm
:
1
npm install --save @chartbrew/plugin-strapi
With yarn
:
1
yarn add @chartbrew/plugin-strapi
Add the following attribute in the config/plugins.js
file:
1
chartbrew: true
Or if you do not have the plugins.js
file yet, add the file with the following contents:
1
2
3
module.exports = () => ({
chartbrew: true,
});
And finally, run the build command:
1
npm run build
Or if you are using yarn
:
1
yarn build
In order for the plugin to work properly, it needs the right credentials to authenticate with Chartbrew.
The plugin can also create charts straight from Strapi, but this needs access to Strapi through an API token.
Follow the instructions below to learn how to configure the plugin.
If you self-host Chartbrew, you will have to enter the frontend and backend addresses. The default values are:
http://localhost:4018
http://localhost:4019
If you want to use the plugin with a managed service account at chartbrew.com, click on the Use managed Chartbrew address button as shown below:
If you run both Strapi and Chartbrew on localhost
or on a non-secure connection (http), you will need to tweak the Strapi security settings. To do this, open the config/middlewares.js
file and add the following attribute:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
module.exports = [
...
{
name: 'strapi::security',
config: {
contentSecurityPolicy: {
useDefaults: true,
directives: {
'connect-src': ["'self'", 'http:', 'https:'],
upgradeInsecureRequests: null,
},
},
},
},
...
];
And don't forget to build the Strapi project again:
1
2
3
4
5
# npm
npm run build
# yarn
yarn build
You can create charts directly from your Strapi dashboards. To do this, you will need to create a Strapi API Token and add it in the Chartbrew settings page.
npm install @chartbrew/plugin-strapi
Check out the available plugin resources that will help you to develop your plugin or provider and get it listed on the marketplace.