5import Affjax.Node as AffjaxNode
6import Data.Foldable (for_)
7import Data.Maybe (Maybe(..))
9import Effect.Aff (Milliseconds(..), launchAff_)
10import Effect.Class.Console as Log
11import GraphQL.FunDeps (class GraphQLReqRes, Gql(..), GraphQL, GraphQLClientAff, graphQL)
12import Test.Spec (describe, it)
13import Test.Spec.Reporter.Console (consoleReporter)
14import Test.Spec.Runner (defaultConfig, runSpec')
16endpoint = "https://api.react-finland.fi/graphql" :: String
18foreign import data ReactFinlandConferences :: GraphQL
20instance graphqlReactFinlandConferences ::
21 GraphQLReqRes ReactFinlandConferences """query {
27""" () ( conferences :: Array { name :: String, id :: String } )
29foreign import data ReactFinlandConference :: GraphQL
31instance graphqlReactFinlandConference ::
32 GraphQLReqRes ReactFinlandConference """query($id:ID!) {
42""" ( id :: String ) ( conference ::
44 , websiteUrl :: String
53client :: GraphQLClientAff
54client = graphQL "https://api.react-finland.fi/graphql" [] AffjaxNode.driver
61 { timeout = Just (Milliseconds 10000.0)
64 [ consoleReporter ] do
65 describe "GraphQL Fundeps" do
67 { conferences } <- client (Gql :: Gql ReactFinlandConferences) {}
68 for_ conferences \{ id } -> do
69 { conference: { websiteUrl, speakers } } <- client (Gql :: Gql ReactFinlandConference) { id }
71 Log.info $ show speakers
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list