mirror of
https://github.com/dillonkearns/elm-pages-v3-beta.git
synced 2024-12-28 22:37:08 +03:00
Inline let binding and rename param.
This commit is contained in:
parent
39b83767b6
commit
09cc5f3247
@ -862,21 +862,14 @@ staticResponseForPage :
|
|||||||
}
|
}
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
staticResponseForPage siteMetadata viewFn =
|
staticResponseForPage staticRoutes viewFn =
|
||||||
-- TODO need all Routes here, and their page paths
|
staticRoutes
|
||||||
-- need to start with hardcoding the static URLs
|
|
||||||
-- eventually, getStaticPaths equivalent
|
|
||||||
siteMetadata
|
|
||||||
|> List.map
|
|> List.map
|
||||||
(\( pagePath, route ) ->
|
(\( pagePath, route ) ->
|
||||||
let
|
Ok
|
||||||
thing =
|
( pagePath
|
||||||
viewFn []
|
, viewFn [] { path = pagePath, frontmatter = route }
|
||||||
{ path = pagePath
|
)
|
||||||
, frontmatter = route
|
|
||||||
}
|
|
||||||
in
|
|
||||||
Ok ( pagePath, thing )
|
|
||||||
)
|
)
|
||||||
|> combine
|
|> combine
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user