apexcharts.js
apexcharts.js copied to clipboard
iOS 12.4 not supported
Description
On Safari iOS 12.4 and below, no charts are displayed. I was also reported a problem on Android 7.0 but did not test myself. I tried with custom code, with the official demos (https://apexcharts.com/javascript-chart-demos/), and with the official codepen (https://codepen.io/apexcharts/pen/bxzgZJ). Nothing shows.
Errors logged in console are :
Can't find variable ResizeObserver
and
TypeError: undefined is not an object (evaluating this.w.globals.dom.Paper.node)
Steps to Reproduce
- Find a device or emulator on iOS 12.4
- Open with safari https://apexcharts.com/javascript-chart-demos/ and try to see the demos. No chart shows.
Reproduction Link
https://apexcharts.com/javascript-chart-demos
https://codepen.io/apexcharts/pen/bxzgZJ
I usually don't piggyback onto issues, but I think it's appropriate here.
Same exact issues with Safari 12 on macOS:
- https://sentry.io/share/issue/08b44283e5234ba6b1ec3e013a4bfe97/
- https://sentry.io/share/issue/4bdfb3599cb247cd8069462b08d71486/
We've had to put a banner across the top of our app, telling users we don't support Safari 12.
I have the same error using apexcharts latest release with:
Safari | 11.1.2 Safari | 12.1.2 Safari | 14.1.2
npm install resize-observer import { install } from "resize-observer"; install();
Adding resize-observer polyfill fixed (for us) for both ie11 and safari 10/11.