thomasloven / lovelace-template-entity-row

🔹 Display whatever you want in an entities card row.
MIT License
210 stars 16 forks source link

Since HA 2021.6.0 this component destroys layout of entity cards #55

Closed KennethLavrsen closed 3 years ago

KennethLavrsen commented 3 years ago

I have had this component installed but not actually used it yet

But just having it installed destroys all entitiy cards making content go all over the place

Here is a screenshot

Note that also entity cards without sliders are goofed. and that I do not use the template entity row. it is just installed via HACS

image

KennethLavrsen commented 3 years ago

And here is a normal screenshot without the component installed

image

thomasloven commented 3 years ago

Did you try release 1.1.2 titled "Important fix for Home Assistant 2021.06" released five days ago and clear your cache?

golles commented 3 years ago

1.1.2 does indeed fix it for me, thanks.

Was btw really hard to update to that version reloading resources and refresh UI (even with CMD+F5) didn't load it, I had to open the javascript file in the browser and CMD+F5 that to get the latest version (https://my-hass/local/template-entity-row.js) Thanks!

thomasloven commented 3 years ago

The whole of Internet works as well as it does because of very aggressive caching in every step, but sometimes it sucks. https://github.com/thomasloven/hass-config/wiki/Lovelace-Plugins#clearing-cache

KennethLavrsen commented 3 years ago

I installed and uninstalled 1.1.2 several times. Problem comes and problem goes away when I remove it. I tried 4 different browsers on 3 different machines. All the same.

Then I tried to add it again. Now it works on one browser on one machine. That js file is very very persistant. Control F5 does not reload it. It seems golles has a point. IOS Safari has no force reload of cache feature (something developers have complained about for years). And even clearing data for specific site does not clear cache. It only seems to clear cookies. The only tool you have is total clear and then you live a miserable life for weeks having to accept cookie pop ups everywhere.

We need a mechanism in HA world to reload these JS files. I have seen other projects do some tricks with putting a rev in the URL

KennethLavrsen commented 3 years ago

Update. On IOS I could force aa refresh the way golles suggests except the URL is wrong when installing with HACS

The URL is https://MY-HA-URL/hacsfiles/lovelace-template-entity-row/template-entity-row.js

Looking up that URL on my IOS device and refreshing a couple of times made the browser finally update the cache

KennethLavrsen commented 3 years ago

Closing issue. The poor mechamism to update cache is a generic issue not related to a single component