- Install Apollo
$ npm install -g apollo 1.9.2
- Fetch Scheme & Generate API Code
cd ____ # project folder
apollo schema:download _______/schema.json --endpoint=__________ # scheme.json location / end point url
apollo codegen:generate --queries="$(find . -name '*.graphql')" --schema=_______/schema.json _______/GraphQLAPI.swift # scheme.json location / generated API code location
$ sh get_gql.sh
- RxSwift (~> 4.0)
- apollo-ios (~>0.9.4)
- Xcode 10.0
- Swift 4.2
RxApolloClient is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'RxApolloClient'
client.rx
.fetch(query: SearchRepositoriesQuery(query: "test"))
client.rx
.watch(query: SearchRepositoriesQuery(query: "test"))
client.rx
.perform(mutation: AddStarMutation(id: "test"))
OhKanghoon, ggaa96@naver.com
RxApolloClient is available under the MIT license. See the LICENSE file for more info.