Module Description
This module provides a Twig extension that enables you to generate charts in Twig using that Charts module API. Make sure you've installed the Charts module (including at least one submodule (and associated library), and set a default library at /admin/config/content/charts).

Your Twig might look something like:

{% set title = 'The Chart Title' %} {% set data = [10, 20, 30] %} {% set series = { 'my_series' : { 'title' : 'What is being plotted', 'data' : data } } %} {% set xaxis = { 'title' : 'X-Axis Label', 'labels' : ['a', 'b', 'c'] } %} {{ chart('my_twig_chart', 'column', title, series, xaxis, [], []) }} If you plan to use translation, use the |t or |trans filter in your Twig.

Project Usage
139
Creation Date
Changed Date
Security Covered
Covered By Security Advisory
Version Available
Production
Module Summary
This module aims to solve the generation of charts in Twig using the Charts module API.
Data Name
charts_twig

OPENAI CHATBOT

OPENAI CHATBOT

12:30:49
Generic Chatbot
Hi, I'm a Drupal module expert powered by OpenAI, answering your questions about the Drupal module ecosystem. How can I be helpful today? Please note that we will log your question.