- Testing end to end with a graphql-yoga server with live queries enabled.
- Also refactored the default `query_` client to be in the `Affjax.Node` module to avoid depending on `urql` across tests.
Example (from the end to end test):
```purescript
main :: Effect Unit
main = do
client :: Client UrqlLiveQueryClient Directives Query _ _ <-
createLiveQueryClient
{ url: "http://localhost:4000/graphql"
, headers: [ ]
}
let
event = liveQuery client "" $ live {} { greetings }
handle <-
HS.subscribe event \e -> do
log "Live Query update received"
logShow e
launchAff_ do
delay $ Milliseconds (3.0 * 1000.0)
liftEffect $ HS.unsubscribe handle
Adding
@live
queries in the style of https://github.com/n1ru4l/graphql-live-queryliveQuery
in theUrql
client