I followed https://chartjs-chart-matrix.pages.dev/integration.html#bundlers-webpack-rollup-etc to create the matrix. i literally pasted the code:
import { Chart } from "chart.js";
import { MatrixController, MatrixElement } from "chartjs-chart-matrix";
Chart.register(MatrixController, MatrixElement);
then pressed CTRL+S and i get the: "cannot read properties of undefined (reading 'prototype')" error
I'm also using nextjs and typescript, if that helps