-
Notifications
You must be signed in to change notification settings - Fork 24
Open
Description
Here is an example of Gleam code:
import app/models/post
import app/pages/home
import app/pages/root.{root}
import framework/renderers
import framework/types/routes.{type RouteParams}
import wisp.{type Request, type Response}
// This action respond only with HTML because a RootRoute can only render HTML.
// See app/routes.gleam.
pub fn index(_request: Request, _params: RouteParams) -> Response {
root(home.build(post.all()))
|> renderers.html
|> wisp.html_response(200)
}app/models/postis from my application, so I have an<project_root>/src/app/models/folder with apost.gleamfile.framework/renderersis the same asapp, I have a<project_root>/src/framework/folder with arenderers.gleamfilewispis an external library installed at the path<project_root>/build/packages/wisp/
Metadata
Metadata
Assignees
Labels
No labels