Skip to content
This repository was archived by the owner on Jul 24, 2023. It is now read-only.
This repository was archived by the owner on Jul 24, 2023. It is now read-only.

BUG: eleventy-load-css fails to handle a single stylesheet in subdirectory pages #47

Description

@johnhunter

Eleventy versions: 0.12.x .. 1.0.x

Minimal reproducable case:
https://github.com/johnhunter/test-eleventy-load

When we have two top-level pages and one page in a sub-directory

index.md
contact.md
about/index.md

They all share a single layout that contains a stylesheet. When built, if we just have the top-level files then the a single css asset file is output as expected. However, with the nested source page:

Steps:

  • Checkout the repo and npm install
  • Run the dev build npm start

Expected:

  • All pages contain a stylesheet link to a single css asset

Actual:

  • The css asset file is output to _site/contact/assets
  • The nested about/index page fails to transform the stylesheet link to the output css asset.
  • The other pages have a 404 stylesheet link that assumes the file is output to _site/assets

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions