summaryrefslogtreecommitdiff
path: root/lore/Biz/Ibb/Influencers.hs
diff options
context:
space:
mode:
Diffstat (limited to 'lore/Biz/Ibb/Influencers.hs')
-rw-r--r--lore/Biz/Ibb/Influencers.hs13
1 files changed, 11 insertions, 2 deletions
diff --git a/lore/Biz/Ibb/Influencers.hs b/lore/Biz/Ibb/Influencers.hs
index beeaf41..f00fe2e 100644
--- a/lore/Biz/Ibb/Influencers.hs
+++ b/lore/Biz/Ibb/Influencers.hs
@@ -1,7 +1,10 @@
{-# LANGUAGE OverloadedStrings #-}
+{-# LANGUAGE DeriveGeneric #-}
module Biz.Ibb.Influencers where
+import Data.Aeson
import Data.Text.Lazy (Text)
+import GHC.Generics (Generic)
data Person = Person
{ _name :: Text
@@ -10,13 +13,19 @@ data Person = Person
, _website :: Text
, _books :: [Book]
, _blurb :: Text
- } deriving (Show, Eq)
+ } deriving (Generic, Show, Eq)
+
+instance FromJSON Person
+instance ToJSON Person
data Book = Book
{ _title :: Text
, _author :: Text
, _amznref :: Text
- } deriving (Show, Eq)
+ } deriving (Generic, Show, Eq)
+
+instance FromJSON Book
+instance ToJSON Book
allPeople :: [Person]
allPeople =