DeckThemes / SDH-CssLoader

Loads CSS dynamically into the steam deck game ui
GNU General Public License v3.0
114 stars 9 forks source link

Clear cache on theme refresh #70

Closed ChrisAnd1998 closed 1 year ago

ChrisAnd1998 commented 1 year ago

For easy editing I am loading the css file from url. It works but to see the changes the browser cache must be cleared and the Deck must be restarted.

shared.css @import url("https://chrisandriessen.nl/steamdeck/shared.css");

suchmememanyskill commented 1 year ago

i don't see how that's our issue.

Also, are you not looking for something like this? https://docs.deckthemes.com/#/CSSLoader/Features?id=%f0%9f%a7%ad-file-watcher

ChrisAnd1998 commented 1 year ago

@suchmememanyskill Thank you for your quick response. The issue is that the file from url in this case https://chrisandriessen.nl/steamdeck/shared.css gets cached so the Css loader will not see any changes because it's cached by the Steam Deck. If Css loader could clear the Decks browser cache this should be fixed. I have added the WATCH file but that does not work as the shared.css file is not being changed.

The contents of that file will always be @import url("https://chrisandriessen.nl/steamdeck/shared.css");

so it actually loads the contents of that online hosted css file https://chrisandriessen.nl/steamdeck/shared.css

.quickaccessmenu_QuickAccessMenu_V0cr-,.quickaccessmenu_Title_34nl5,.quickaccessmenu_Tab_1S76C {
    background: blue;
}

.quickaccessmenu_Title_34nl5 {
    box-shadow: none;
}

.gamepadhomerecentgames_RecentGamesHeader_35iRe {
    display:none!important;
}
suchmememanyskill commented 1 year ago

Again, i don't see how that's our issue. You're currently doing something i think is outside the scope of this project (cssloader loads css from local files, not remote files).

The watch feature allows you to remotely edit the local .css files via sftp or something, and they'll automatically get reloaded

ChrisAnd1998 commented 1 year ago

@suchmememanyskill Thank you. I will try to find another solution.

ChrisAnd1998 commented 1 year ago

@suchmememanyskill Currently have set it up with sshfs works like a charm! ;)