yesod web framework book
play

Yesod Web Framework Book 2 | OpenTopic | TOC Contents - PDF document

Yesod Web Framework Book 2 | OpenTopic | TOC Contents Basics......................................................................................................................................5


  1. Yesod Web Framework Book

  2. 2 | OpenTopic | TOC Contents Basics......................................................................................................................................5 Introduction.............................................................................................................................................. 5 Type Safety.................................................................................................................................. 5 Concise.........................................................................................................................................5 Performance................................................................................................................................. 5 Modular........................................................................................................................................ 6 A solid foundation........................................................................................................................6 Introduction to Haskell.............................................................................................................................6 Language Pragmas....................................................................................................................... 6 Quasi-quotation............................................................................................................................ 6 Type families................................................................................................................................6 Basics....................................................................................................................................................... 6 Getting Yesod...............................................................................................................................7 Library versus Framework........................................................................................................... 7 Hello World..................................................................................................................................7 Routing.........................................................................................................................................8 Handler function...........................................................................................................................8 The Foundation............................................................................................................................ 8 Running........................................................................................................................................ 9 Resources and type-safe URLs.................................................................................................... 9 Development server....................................................................................................................10 Summary.................................................................................................................................... 10 Templates............................................................................................................................................... 10 Type Safety................................................................................................................................ 11 Basic syntax................................................................................................................................12 Tags............................................................................................................................................ 14 Variables.....................................................................................................................................15 Function Application..................................................................................................................15 Hamlet Control Structures..........................................................................................................16 Comments...................................................................................................................................17 Templates in External Files........................................................................................................17 Types.......................................................................................................................................... 19 Lucius.........................................................................................................................................19 Hamlet Syntax............................................................................................................................20 Summary.................................................................................................................................... 20 Widgets...................................................................................................................................................20 What's in a Widget?....................................................................................................................21 Building Widgets........................................................................................................................21 Yesod Typeclass.....................................................................................................................................22 Rendering and Parsing URLs.....................................................................................................23 defaultLayout............................................................................................................................. 25 Custom error pages.....................................................................................................................27 Summary.................................................................................................................................... 28 Routing and Handlers.............................................................................................................................28 Route Syntax.............................................................................................................................. 28 Dispatch......................................................................................................................................31 The GHandler Monad.................................................................................................................32 Summary.................................................................................................................................... 34 Basic Forms............................................................................................................................................35 Random bananas........................................................................................................................ 35 Summary.................................................................................................................................... 42

Recommend


More recommend