From 71aae18960522ec814e74d84e3d377274e2e506e Mon Sep 17 00:00:00 2001 From: Jeroen <1492076+jeroen1602@users.noreply.github.com> Date: Mon, 9 Sep 2024 13:01:51 +0200 Subject: [PATCH] Added support for the Angular compiler. The Angular compiler looks for the main field using a few fields in the package.json. The order it uses is: - es2020 - es2015 - browser - module - main The first entry the Angular compiler would find before this change was the 'main' entry point. This is however compiled as `common js` and Angular is looking for an `esm` so it would complain (it would still work though). Adding `es2020` as an entry point fixes this problem. --- package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/package.json b/package.json index 6dd875577..2554cbd96 100644 --- a/package.json +++ b/package.json @@ -7,6 +7,7 @@ "url": "https://github.com/apexcharts/apexcharts.js.git" }, "main": "dist/apexcharts.common.js", + "es2020": "dist/apexcharts.esm.js", "unpkg": "dist/apexcharts.js", "jsdelivr": "dist/apexcharts.js", "typings": "types/apexcharts.d.ts",