Skip to content
/ hugo Public
forked from gohugoio/hugo

Commit

Permalink
dartsass: Resolve directory paths to directory index files
Browse files Browse the repository at this point in the history
  • Loading branch information
jmooring committed Sep 13, 2024
1 parent fe7e137 commit 9177a4e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion resources/resource_transformers/tocss/dartsass/transform.go
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,11 @@ func (t importResolver) CanonicalizeURL(url string) (string, error) {
} else if strings.HasPrefix(name, "_") {
namePatterns = []string{"_%s.scss", "_%s.sass", "_%s.css"}
} else {
namePatterns = []string{"_%s.scss", "%s.scss", "_%s.sass", "%s.sass", "_%s.css", "%s.css"}
namePatterns = []string{
"_%s.scss", "%s.scss", "%s/_index.scss",
"_%s.sass", "%s.sass", "%s/_index.sass",
"_%s.css", "%s.css", "%s/_index.css",
}
}

name = strings.TrimPrefix(name, "_")
Expand Down

0 comments on commit 9177a4e

Please sign in to comment.