Lovelace: Home Feed Card

Wh I said no more errors, I was referring to custom element doesn’t exist.
The custom card is:

calendars:

  • calendar.bschatzow_gmail_com
    entities:
  • entity: binary_sensor.wyzesense_779324f0
  • entity: binary_sensor.wyzesense_778a7342
  • entity: device_tracker.bill_pixel_gps
    show_empty: true
    title: Home Feed
    type: ‘custom:home-feed-card’ `

I am still confused on the resources path called out.
/community_plugin/lovelace-home-feed-card/lovelace-home-feed-card.js
I read this is that the js file needs to be in a directory under www/community_plugin. This is not where HACS installs the file.

Also this card works on my android tablet with Chrome, but not on my windows 10 with chrome. Both are at the latest version. Maybe a js problem with chrome? Strange as there were no windows updates last week and it was working great. Tried clearing cache, etc no difference.

Can you try opening the Chrome Developer Tools (Ctrl+Shift+I or F12) and see if any error messages appear in the Console tab?

Does your config look this this (I think the formatting of your config has got a bit messed up in your post)?

calendars:
  - calendar.bschatzow_gmail_com
entities:
  - entity: binary_sensor.wyzesense_779324f0
  - entity: binary_sensor.wyzesense_778a7342
  - entity: device_tracker.bill_pixel_gps
show_empty: true
title: Home Feed
type: 'custom:home-feed-card'

I am still confused on the resources path called out.
/community_plugin/lovelace-home-feed-card/lovelace-home-feed-card.js
I read this is that the js file needs to be in a directory under www/community_plugin. This is not where HACS installs the file.

HACS downloads the files to www/community
/community_plugin is a URL which HACS maps to that location. This allows it to avoid issues with caching, without that you would need to add a version number to the end of the URL when there is a new version.

Thanks. The formatting did get messed up. I did use the
before I pasted For some reason the - got changed to bullets. I just saw that you need three ` for correct formatting. At least one problem resolved.

On HACS each developer creates a map for their file? Not sure how this is easier than having the url file point to the file and path name. I’m still so I’m sure there are valid reasons. I needed to just understand where stuff belongs. Many of the directions for custom cards have conflicting information. Makes it hard for new people to understand what is correct. Again, thanks for the card, it works great and your willingness to help. Some cards have -type were others have - url. Not sure which is the correct way.

On Chrome console, what am I looking for.
This is what it shows.

Access to script at 'https://unpkg.com/[email protected]/src/lib/units/hour?module' from origin 'https://bschatzow.duckdns.org:8123' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header has a value 'http://hassio.local:8123' that is not equal to the supplied origin.
hour:1 Failed to load resource: net::ERR_FAILED
2default_view:1 Uncaught (in promise) TypeError: Failed to fetch dynamically imported module: https://unpkg.com/[email protected]/src/moment.js?module
4lovelace-home-feed-card.js:39 Loaded custom-card-helpers module.
2default_view:1 Uncaught (in promise) TypeError: Failed to fetch dynamically imported module: https://unpkg.com/[email protected]/src/moment.js?module
Promise.then (async)
loadModules @ lovelace-home-feed-card.js:25
HomeFeedCard @ lovelace-home-feed-card.js:20
fa @ create-card-element.ts:71
ya @ create-card-element.ts:98
value @ hui-view.ts:60
(anonymous) @ hui-view.ts:286
value @ hui-view.ts:285
value @ hui-view.ts:214
performUpdate @ updating-element.js:526
_enqueueUpdate @ updating-element.js:460
async function (async)
_enqueueUpdate @ updating-element.js:446
_requestUpdate @ updating-element.js:413
initialize @ updating-element.js:268
initialize @ lit-element.js:95
O @ updating-element.js:98
V @ lit-element.js:46
r @ hui-view.ts:50
value @ hui-root.ts:652
(anonymous) @ hui-root.ts:492
setTimeout (async)
(anonymous) @ render-status.ts:2
(anonymous) @ web-animations-next-lite.min.js:15
requestAnimationFrame (async)
(anonymous) @ web-animations-next-lite.min.js:15
r @ render-status.ts:2
value @ hui-root.ts:492
performUpdate @ updating-element.js:526
_enqueueUpdate @ updating-element.js:460
async function (async)
_enqueueUpdate @ updating-element.js:446
_requestUpdate @ updating-element.js:413
set @ updating-element.js:166
commit @ parts.js:368
commit @ parts.js:111
update @ template-instance.js:40
__commitTemplateResult @ parts.js:236
commit @ parts.js:186
s @ render.js:44
V.render @ shady-render.js:251
update @ lit-element.js:166
performUpdate @ updating-element.js:508
_enqueueUpdate @ updating-element.js:460
async function (async)
_enqueueUpdate @ updating-element.js:446
_requestUpdate @ updating-element.js:413
set @ updating-element.js:166
value @ ha-panel-lovelace.ts:310
setEditMode @ ha-panel-lovelace.ts:277
value @ hui-root.ts:541
handleEvent @ parts.js:434
__boundHandleEvent @ parts.js:400
F @ gestures.js:662
q @ gestures.js:1058
click @ gestures.js:1017
N @ gestures.js:450
lovelace-home-feed-card.js:39 Loaded custom-card-helpers module.
default_view:1 Uncaught (in promise) TypeError: Failed to fetch dynamically imported module: https://unpkg.com/[email protected]/src/moment.js?module
'``
I don't know if this shows the problem and if it does, how to fix it.

Has all of the new features been added to the readme on github? I am not seeing anywhere to enable compact mode. Unless I am blind, I am not seeing updates to the documentation.

Suddenly the custom card stopped to work without any entries in the logfile…
Simply doesn’t show anymore what i put inside the configuration.
Is anyone else experimenting this?

Are you getting errors like this in the Javascript console?

Access to script at '...' has been blocked by CORS policy

if so, there was a problem with unpkg.com which, although it has been fixed, it looks like some packages need to be cleared from the cache on their server. I’ve asked for the moment package to be cleared so that should hopefully fix it.

1 Like

The new beta features are from the experimental branch. You can access the readme file here:

Yes, in the console that’s the error, so i hope it will be fixed soon! Thanks!

Can you also try clearing the cache in the browser? I think this may now be resolved in the unpkg CDN (they seem to be loading correctly for me in my own setup) but the responses have the Cache-Control max-age set to 1 year so the browser may still be caching an old response.

I cleared cache and still doesn’t show on PC. Works on Android. Both Chrome browsers.

Same here… works on tablet and mobile but not on PC.

Is this better now? I’ve had confirmation that the Moment module has been cleared in the unpkg cache.
If it still doesn’t work after cleaning your browser cache please let me know the details of the error in the console in case it’s a different module or some other issue.

No, stopped again to work since this morning.
In the console i get:

Do you use a proxy server to access the Internet? If so, it may be doing its own caching. In that case doing both a clear cache and force reload (in Chrome there’s an option to do these together if you hold down on the reload button with developer tools open) may help.

Otherwise I don’t know why this is still happening for you as it is loading fine from here in all browsers (Chrome, Firefox, and Safari).

Still broken for me also.

Access to script at 'https://unpkg.com/[email protected]/src/lib/units/hour?module' from origin 'https://xcxxc
duckdns.org:8123' has been blocked by CORS policy: The 'Access-Control-Allow-Origin' header has a value 'http://hassio.local:8123' that is not equal to the supplied origin.
units.js:5 GET https://unpkg.com/[email protected]/src/lib/units/hour?module net::ERR_FAILED
2default_view:1 Uncaught (in promise) TypeError: Failed to fetch dynamically imported module: https://unpkg.com/[email protected]/src/moment.js?module
Promise.then (async)
loadModules @ lovelace-home-feed-card.js:25
HomeFeedCard @ lovelace-home-feed-card.js:20
fa @ create-card-element.ts:71
ya @ create-card-element.ts:98
value @ hui-view.ts:60
value @ hui-view.ts:334
t.addEventListener.once @ hui-view.ts:68
r @ fire_event.ts:76
(anonymous) @ create-card-element.ts:111
Promise.then (async)
ya @ create-card-element.ts:109
value @ hui-view.ts:60
(anonymous) @ hui-view.ts:286
value @ hui-view.ts:285
value @ hui-view.ts:214
performUpdate @ updating-element.js:526
_enqueueUpdate @ updating-element.js:460
async function (async)
_enqueueUpdate @ updating-element.js:446
_requestUpdate @ updating-element.js:413
initialize @ updating-element.js:268
initialize @ lit-element.js:95
O @ updating-element.js:98
V @ lit-element.js:46
r @ hui-view.ts:50
value @ hui-root.ts:652
(anonymous) @ hui-root.ts:492
setTimeout (async)
(anonymous) @ render-status.ts:2
(anonymous) @ web-animations-next-lite.min.js:15
requestAnimationFrame (async)
window.requestAnimationFrame @ web-animations-next-lite.min.js:15
r @ render-status.ts:2
value @ hui-root.ts:492
performUpdate @ updating-element.js:526
_enqueueUpdate @ updating-element.js:460
async function (async)
_enqueueUpdate @ updating-element.js:446
_requestUpdate @ updating-element.js:413
initialize @ updating-element.js:268
initialize @ lit-element.js:95
O @ updating-element.js:98
V @ lit-element.js:46
r @ hui-root.ts:66
_clone @ template-instance.js:84
__commitTemplateResult @ parts.js:244
commit @ parts.js:186
s @ render.js:44
V.render @ shady-render.js:251
update @ lit-element.js:166
performUpdate @ updating-element.js:508
_enqueueUpdate @ updating-element.js:460
async function (async)
_enqueueUpdate @ updating-element.js:446
_requestUpdate @ updating-element.js:413
set @ updating-element.js:166
value @ ha-panel-lovelace.ts:179
value @ ha-panel-lovelace.ts:143
performUpdate @ updating-element.js:524
_enqueueUpdate @ updating-element.js:460
async function (async)
_enqueueUpdate @ updating-element.js:446
_requestUpdate @ updating-element.js:413
initialize @ updating-element.js:268
initialize @ lit-element.js:95
O @ updating-element.js:98
V @ lit-element.js:46
o @ ha-panel-lovelace.ts:55
value @ hass-router-page.ts:271
value @ hass-router-page.ts:291
_currentLoadProm.c.then._currentLoadProm @ hass-router-page.ts:197
Promise.then (async)
value @ hass-router-page.ts:188
performUpdate @ updating-element.js:508
_enqueueUpdate @ updating-element.js:460
async function (async)
_enqueueUpdate @ updating-element.js:446
_requestUpdate @ updating-element.js:413
set @ updating-element.js:166
value @ hass-router-page.ts:259
async function (async)
value @ hass-router-page.ts:256
value @ partial-panel-resolver.ts:115
value @ partial-panel-resolver.ts:82
performUpdate @ updating-element.js:526
_enqueueUpdate @ updating-element.js:460
async function (async)
_enqueueUpdate @ updating-element.js:446
_requestUpdate @ updating-element.js:413
initialize @ updating-element.js:268
O @ updating-element.js:98
n @ hass-router-page.ts:49
n @ partial-panel-resolver.ts:65
_clone @ template-instance.js:84
__commitTemplateResult @ parts.js:244
commit @ parts.js:186
s @ render.js:44
V.render @ shady-render.js:251
update @ lit-element.js:166
performUpdate @ updating-element.js:508
_enqueueUpdate @ updating-element.js:460
async function (async)
_enqueueUpdate @ updating-element.js:446
_requestUpdate @ updating-element.js:413
initialize @ updating-element.js:268
initialize @ lit-element.js:95
O @ updating-element.js:98
V @ lit-element.js:46
r @ home-assistant-main.ts:36
_clone @ template-instance.js:84
__commitTemplateResult @ parts.js:244
commit @ parts.js:186
update @ template-instance.js:40
__commitTemplateResult @ parts.js:236
commit @ parts.js:186
s @ render.js:44
V.render @ shady-render.js:251
update @ lit-element.js:166
performUpdate @ updating-element.js:508
_enqueueUpdate @ updating-element.js:460
async function (async)
_enqueueUpdate @ updating-element.js:446
_requestUpdate @ updating-element.js:413
set @ updating-element.js:166
value @ hass-base-mixin.ts:49
(anonymous) @ connection-mixin.ts:137
n @ haws.es.js:1
(anonymous) @ haws.es.js:1
Promise.then (async)
c @ haws.es.js:1
u @ haws.es.js:1
subscribe @ haws.es.js:1
S @ haws.es.js:1
(anonymous) @ core.ts:77
Promise.then (async)
166 @ core.ts:71
o @ bootstrap:63
(anonymous) @ bootstrap:198
(anonymous) @ bootstrap:198
2lovelace-home-feed-card.js:39 Loaded custom-card-helpers module.

No proxy server here.

No, i don’t use any proxy server…

@bschatzow, you’re showing your duckdns url. Just for info.

1 Like

I still get no card and more, trying to update to the latest via HACS it seems not working the process of updating… The files inside /local/www) are updated, but the UI HACS shows always the old release also after clicking on update…

I had a similar issue with the update to 0.3.0 (non-beta). I’ve pushed 0.3.1 now, but it isn’t actually any different to 0.3.0. Try select 0.3.0b3 from the dropdown and clicking Reinstall or Upgrade and then try the upddate to 0.3.1 again.

I’m trying to find out why you may still be having issues with the CORS errors despite the cache being cleared.

Just updated to the .3.1 and still have the CORS errors on chrome.