# Missing nodes in Home Assistant addon when loading extra resources

**URL:** https://discourse.nodered.org/t/missing-nodes-in-home-assistant-addon-when-loading-extra-resources/88793
**Category:** Developing Nodes
**Tags:** home-assistant
**Created:** [19 June 2024 09:10 UTC](https://discourse.nodered.org/t/missing-nodes-in-home-assistant-addon-when-loading-extra-resources/88793 "2024-06-19T09:10:07Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![MoonDev](https://avatars.discourse-cdn.com/v4/letter/m/bbce88/32.png) [@MoonDev](https://discourse.nodered.org/u/MoonDev)
#### Post date: [19 June 2024 09:10 UTC](https://discourse.nodered.org/t/missing-nodes-in-home-assistant-addon-when-loading-extra-resources/88793/1 "2024-06-19T09:10:07Z")

</div>

Hello,

I noticed an issue with my node palette [@lunatone/node-red-dali](https://flows.nodered.org/node/@lunatone/node-red-dali) in the Node-RED sidebar of the Home Assistant addon where some of the nodes in the palette are missing and cannot be used. When accessing the Node-RED editor directly with the 1880 port no nodes are missing. It seems like it is because the affected nodes rely on the Node-RED feature to load extra resources in HTML files (See: [Loading extra resources in the editor : Node-RED](https://nodered.org/docs/creating-nodes/resources)). The URL that is requested when using Node-RED from the sidebar in Home Assistant doesn't work and I get this error in the browser.

 ![grafik](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/9/3/93cf0e7126c931bf099b289637176804ffda38e0.png)

Has anyone had a similar problem and knows a way around that?

Edit:  
This is how I access the resources:

```auto
<script type="module">
    import { DALICommands } from "../resources/@lunatone/node-red-dali/dali-frame-html.js";
    ...
</script>

```

but I also tried it like this:

```auto
<script src="resources/@lunatone/node-red-dali/dali-commands.js"></script>

```

---

<div class="post-metadata">

### Author: ![GogoVega](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/gogovega/32/71313_2.png) [@GogoVega](https://discourse.nodered.org/u/GogoVega)
#### Post date: [19 June 2024 09:25 UTC](https://discourse.nodered.org/t/missing-nodes-in-home-assistant-addon-when-loading-extra-resources/88793/2 "2024-06-19T09:25:14Z")

</div>

Hi,  
And with this?

```auto
<script type="text/javascript" src="resources/@lunatone/node-red-dali/dali-commands.js"></script>

```

Not sure the export works there 🤔

```js
export{DALICommands}from"./common/dali-commands.js";

```

---

<div class="post-metadata">

### Author: ![MoonDev](https://avatars.discourse-cdn.com/v4/letter/m/bbce88/32.png) [@MoonDev](https://discourse.nodered.org/u/MoonDev)
#### Post date: [19 June 2024 13:56 UTC](https://discourse.nodered.org/t/missing-nodes-in-home-assistant-addon-when-loading-extra-resources/88793/3 "2024-06-19T13:56:14Z")

</div>

Thanks for trying to help!

I noticed that I didn't entirely understand how these relative paths work in HTML. So I replaced the double dots in my import path with a single one and it suddenly worked as expected.

```auto
<script type="module">
    import { DALICommands } from "./resources/@lunatone/node-red-dali/common/dali-commands.js";
    ...
</script>

```

> [@GogoVega](#):
>
> Not sure the export works there 🤔
> 
> `export{DALICommands}from"./common/dali-commands.js";`

It did work so far but I replaced this file anyways. I'm now importing the dali-commands.js directly.

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [3 July 2024 13:57 UTC](https://discourse.nodered.org/t/missing-nodes-in-home-assistant-addon-when-loading-extra-resources/88793/4 "2024-07-03T13:57:05Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
