Move lovelace tabs up beside header - custom js

I want to move my lovelace tabs up beside the title , and to do that i can use som simple javascript to get the following result:

Now i just wan to make the javascript load by it self everytime the page is loaded. What is the best practise for this in Home Assistant?

No clue if this is best practice, but take a look here to load a *.js file.

I tried it out but it doesn’t load any js file. I just made a simple js file in my www folder called testfile.js, and attempted to load it in the top with the raw editor inside home asssitant like so:

resources:
  - type: js
    url: /local/testfile.js

The file only contains console.log("test"); but nothing ever shows in my chrome console, and the network tab doesn’t show any file with that name.

Works for me.
Auswahl_311
Can you open the file with
<your_ha_ip>:8123/local/testfile.js ?
What HA version are you on?
After 0.107.x the resources are loaded from configuration.yaml if you’re in yaml mode, or with the UI (Configuration -> Lovelace Dashboards -> Resources)

I got it to work by using the UI :smiley: Thanks !

Cool!
Would you mind sharing your js file for the header? :slightly_smiling_face: