mathiassm
Safe HaskellNone
LanguageGHC2024

MathiasSM.CleanURL

Synopsis

Documentation

outputPath :: FilePath -> FilePath #

The output file for a public path: `contact` becomes `contactindex.html`, while a path with an extension (like `/404.html`) is kept as is.

pathRoute :: Metadata -> Routes #

Route from the `path:` front matter, laid out by outputPath

cleanIndex :: String -> String #

Strips a URL of its index.html suffix

cleanIndexUrls :: Item String -> Compiler (Item String) #

Cleans all URLs

cleanIndexHtmls :: Item String -> Compiler (Item String) #

Cleans all instances of /index, that might not be a recognized as a URL