Hello!
On my page
I implemented the following code from the cookbook for art directing pages…
<!-- custom css -->
<?php
if($page->uid() !== "projects"){
echo css($page->files()->filterBy('extension', 'css')->pluck('url')) ;
} ?>
which surpisingly (for me) creates a url that leads to the media folder.
in my case:
<link href="https://eriknorden.com/media/pages/animations/2768874d79-1720611268/animations.css" rel="stylesheet">
but it works at least on my end. However the console throughs an error
Failed to load resource: the server responded with a status of 404 ()
https://eriknorden.com/media/pages/animations/2768874d79-1720611268/animations.css.map
Could I simple create a url that points to the directorys css-file ?