Skip to content

Commit

Permalink
Fix Chart.js encore compilation
Browse files Browse the repository at this point in the history
  • Loading branch information
smnandre committed Apr 14, 2024
1 parent 09797ee commit fd99323
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/Chartjs/assets/dist/controller.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { Controller } from '@hotwired/stimulus';
import Chart from 'chart.js/auto';
import { Chart, registerables } from 'chart.js';

Chart.register(...registerables);
let isChartInitialized = false;
class default_1 extends Controller {
constructor() {
Expand Down
4 changes: 3 additions & 1 deletion src/Chartjs/assets/src/controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@
'use strict';

import { Controller } from '@hotwired/stimulus';
import Chart from 'chart.js/auto';
import { Chart, registerables } from 'chart.js';

Chart.register(...registerables);

let isChartInitialized = false;

Expand Down

0 comments on commit fd99323

Please sign in to comment.