jcamposv
03/10/2017, 11:38 PMjcamposv
03/10/2017, 11:38 PMjcamposv
03/10/2017, 11:39 PMjcamposv
03/10/2017, 11:39 PMjcamposv
03/10/2017, 11:40 PMjcamposv
03/10/2017, 11:40 PMjcamposv
03/10/2017, 11:41 PMartyom
03/11/2017, 3:47 AMmartin
03/11/2017, 4:45 AMLife Purpose App
built on the graph.cool
platform. Truly couldnโt have come this far without the amazing people working at graph.cool and the technology they built (and I tried several prior to finding graphcool) Stay tuned. https://www.lifepurposeapp.com/yordi-twinski
03/11/2017, 12:10 PMartyom
03/11/2017, 12:21 PMartyom
03/11/2017, 12:21 PMstephen.sugden
03/11/2017, 3:22 PMartyom
03/11/2017, 6:11 PMlpil
03/11/2017, 7:04 PMdrk
03/11/2017, 8:02 PMdrk
03/11/2017, 8:42 PMdrk
03/11/2017, 8:42 PMdrk
03/11/2017, 8:43 PMimport ApolloClient, { createNetworkInterface } from 'apollo-client'
let apolloClient = null
export const initClient = (opts) => {
if (!process.browser) return createClient(opts)
if (!apolloClient) {
apolloClient = createClient(opts)
}
return apolloClient
}
const createClient = (opts) => {
return new ApolloClient({
ssrMode: !process.browser,
dataIdFromObject: result => result.id || null,
networkInterface: createGraphCoolNetworkInterface(opts)
})
}
const createGraphCoolNetworkInterface = (opts) => {
const networkInterface = createNetworkInterface({
uri: '<https://api.graph.cool/simple/v1/cj008phtn40om0134wa1qgayz>',
opts: {
...opts,
credentials: 'same-origin'
}
})
if (process.browser) {
networkInterface.use([{
applyMiddleware (req, next) {
if (!req.options.headers) {
req.options.headers = {}
}
if (localStorage.getItem('auth0IdToken')) {
req.options.headers.authorization = (
`Bearer ${localStorage.getItem('auth0IdToken')}`
)
}
next()
}
}])
}
return networkInterface
}
drk
03/11/2017, 8:45 PMrequest to <https://api.graph.cool/simple/v1/cj008phtn40om0134wa1qgayz> failed, reason: write EPROTO 140736740590528:error:14077410:SSL routines:SSL23_GET_SERVER_HELLO:sslv3 alert handshake failure:../deps/openssl/openssl/ssl/s23_clnt.c:769:\n
joao.santos
03/12/2017, 8:27 AMafgh
03/12/2017, 9:20 AMartyom
03/12/2017, 12:09 PMsteida
03/12/2017, 6:12 PMschickling
03/12/2017, 6:39 PMartyom
03/12/2017, 7:38 PMjoao.santos
03/12/2017, 8:16 PMjoao.santos
03/12/2017, 8:17 PMmonkeybonkey
03/12/2017, 11:06 PMpkunwar
03/13/2017, 7:18 AM