-
-
Notifications
You must be signed in to change notification settings - Fork 92
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Potential fix for not running on old iOS #414
Comments
Thanks for the hint, I'll check it out 👍 |
This is great to see as I have HA running on an old iPad in the kitchen and it works fine but since Power Card Plus has been the primary card on the main dashboard, it's not worked on the iPad so hopefully this means that the old tech has a future again! |
Can you check if this fixes the issue, there are still two Edit: please make sure in the console shows the version 0.2.0-414 to make sure you are using the correct version |
I've had a look deeper in the code at this (I'm pretty new to HA and am using an old iPad in the kitchen too!). The issue comes from So:
I'll send over a PR |
I have a potential fix for bug #150.
The card is failing to load on on old iOS devices as Safari/Webkit only supported the nullish coalescing operator '??' from iOS version 13.4.
I searched the installed www/community/power-flow-card-plus/power-flow-card-plus.js file for instances of "??" and there were 2 places where it appeared.
I edited
super(a ?? l)
tosuper(( a != null ) ? a : l)
ando ?? (o = [e, ...t()])
to(o != null) ? o : (o = [e, ...t()])
in place and deleted the .gz version of the file, and it works perfectly on an old iPad mini running iOS 12.5.7Sorry I don't know how to fix this in your code/release process but hopefully this points the right direction. Maybe some options to send through babel to target older browsers?
The text was updated successfully, but these errors were encountered: