From 9b7a19f4d2507ba7c026c1a70b885f18c26ebd8c Mon Sep 17 00:00:00 2001 From: Kevin Matsubara Date: Wed, 7 May 2025 22:47:16 +0200 Subject: [PATCH] Update Main.hs file with Scotty example code. --- app/Main.hs | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/app/Main.hs b/app/Main.hs index 65ae4a0..2fb43cc 100644 --- a/app/Main.hs +++ b/app/Main.hs @@ -1,4 +1,9 @@ -module Main where +{-# LANGUAGE OverloadedStrings #-} + +import Web.Scotty main :: IO () -main = putStrLn "Hello, Haskell!" +main = scotty 3000 $ + get "/:word" $ do + beam <- pathParam "word" + html $ mconcat ["

Scotty, ", beam, " me up!

"] \ No newline at end of file