Tyssen Posted March 8 Share Posted March 8 Does anything like https://github.com/clubstudioltd/craft-asset-rev exist for PW? I create a manifest.json file using my build process, which contains code something like {"css/app.css":"css/app-65445d4baa.css","js/app.js":"js/app-889f5dca36.js"} and then in the template I'd have {{ rev('css/app.css') }} which replaces that with whatever is in the manifest file. Link to comment Share on other sites More sharing options...
bernhard Posted March 8 Share Posted March 8 Sure, there are different options. https://processwire.com/api/ref/config/version-url/ Or RockFrontend: $rockfrontend->styles()->add("/your/asset.css") Which will automatically add cache busting timestamps based on filemtime. And probably many more ? 1 1 Link to comment Share on other sites More sharing options...
Tyssen Posted March 9 Author Share Posted March 9 @bernhard that looks cool, I'll check it out more closely. BTW, https://github.com/baumrock/RockFrontend/blob/main/profiles/rock/files/site/templates/_main.php is 404. Link to comment Share on other sites More sharing options...
bernhard Posted March 11 Share Posted March 11 On 3/9/2024 at 11:41 PM, Tyssen said: https://github.com/baumrock/RockFrontend/blob/main/profiles/rock/files/site/templates/_main.php is 404. Where did you find this link? It's from an older version. I renamed the profiles at some point: https://github.com/baumrock/RockFrontend/tree/main/profiles Link to comment Share on other sites More sharing options...
Tyssen Posted March 11 Author Share Posted March 11 27 minutes ago, bernhard said: Where did you find this link? It's from an older version. I renamed the profiles at some point: https://github.com/baumrock/RockFrontend/tree/main/profiles https://processwire.com/modules/rock-frontend/ under example _main.php Link to comment Share on other sites More sharing options...
bernhard Posted March 11 Share Posted March 11 Thx @Tyssen I've updated that readme to point to the "new" docs: https://www.baumrock.com/en/processwire/modules/rockfrontend/docs/ Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now