It allows you to execute queries and mutations against a GraphQL server, and returns results as query-specific Swift types. This means you don’t have to deal with parsing JSON, or passing around dictionaries and making clients cast values to the right type manually. You also don't have to write model types yourself, because these are generated from the GraphQL definitions your UI uses.
As the generated types are query-specific, you're only able to access data you actually specify as part of a query. If you don't ask for a field, you won't be able to access the corresponding property. In effect, this means you can now rely on the Swift type checker to make sure errors in data access show up at compile time. With our Xcode integration, you can conveniently work with your UI code and corresponding GraphQL definitions side by side, and it will even validate your query documents, and show errors inline.
Apollo iOS does more than simply run your queries against a GraphQL server: It normalizes query results to construct a client-side cache of your data, which is kept up to date as further queries and mutations are run. This means your UI is always internally consistent, and can be kept fully up-to-date with the state on the server with the minimum number of queries required.
This combination of models with value semantics, one way data flow, and automatic consistency management, leads to a very powerful and elegant programming model that allows you to eliminate common glue code and greatly simplifies app development.
If you are new to Apollo iOS there are two ways to get started:
There is also comprehensive documentation including an API reference.
All releases are catalogued and we maintain a changelog which details all changes to the library.
The roadmap is a high-level document that describes the next major steps or milestones for this project. We are always open to feature requests, and contributions from the community.
This project is being developed using Xcode 12.5 and Swift 5.4.
If you open Apollo.xcodeproj
, you should be able to run the tests of the Apollo, ApolloSQLite, and ApolloWebSocket frameworks on your Mac or an iOS Simulator.
NOTE: Due to a change in behavior in Xcode 11's git integration, if you check this repo out using Xcode, please close the window Xcode automatically opens using the Swift Package manager structure, and open the
Apollo.xcodeproj
file instead.
Some of the tests run against a simple GraphQL server serving the Star Wars example schema (see installation instructions there).
If you'd like to contribute, please refer to the Apollo Contributor Guide.
Apollo builds open-source software and a graph platform to unify GraphQL across your apps and services. We help you ship faster with:
Check out the Odyssey learning platform, the perfect place to start your GraphQL journey with videos and interactive code challenges. Join the Apollo Community to interact with and get technical help from the GraphQL community.
将命令: apollo create mybroker 替换为: sh apollo create mybroker 转载:Ask Ubuntu
原文地址:The future of state management 原文作者:Peggy Rayzis 译文出自:掘金翻译计划 本文永久链接:github.com/xitu/gold-m… 译者:yct21 当一个应用的规模逐渐扩张,其所包含的应用状态一般也会变得更加复杂。作为开发者,我们可能既要协调从多个远端服务器发送来的数据,也要管理好涉及 UI 交互的本地数据。我们需要以一种合适的方法存
最近在协助调研 Apollo 生成的代码是否有可能跨 Query 共享模型的问题,虽然初步结论是不能,并不是预期的结果,但是在调研过程中积累的一些经验,有必要记录下。如果你也对 Graphql 感兴趣,不妨先从 Github 的 Graphql API 来切手实践。 关于 Graphql 官网 尽管只是做客户端的一些实践,我还是建议你先过一遍 Graphql 官网的学习指南。这样能更快速地理解概念
百度Apollo采用bazel作为代码编译构建工具 每个模块下都有一个build文件,其作用是按照bazel的格式来编译代码的。 关于如何使用bazel编译c++代码,可以见如下网址: 安装教程 - https://docs.bazel.build/versions/master/install.html bazel教程 - https://docs.bazel.build/versions/ma
最近在协助调研 Apollo 生成的代码是否有可能跨 Query 共享模型的问题,虽然初步结论是不能,并不是预期的结果,但是在调研过程中积累的一些经验,有必要记录下。如果你也对 Graphql 感兴趣,不妨先从 Github 的 Graphql API 来切手实践。 关于 Graphql 官网 尽管只是做客户端的一些实践,我还是建议你先过一遍 Graphql 官网的学习指南。这样能更快速地理解概念
Apollo(阿波罗)是携程框架部门研发的分布式配置中心,能够集中化管理应用不同环境、不同集群的配置,配置修改后能够实时推送到应用端,并且具备规范的权限、流程治理等特性,适用于微服务配置管理场景。 Swoft 基于 Apollo 提供的 API,在之上进行封装,使之能在 Swoft 中快速使用。 安装 swoft/whoops 作为一个额外的扩展组件,需要手动安装: Composer 安装 com
Apollo以ActiveMQ原型为基础,是一个更快、更可靠、更易于维护的消息代理工具。Apache称Apollo为最快、最强健的 STOMP(Streaming Text Orientated Message Protocol,流文本定向消息协议)服务器。 Apollo的特性如下: 支持Stomp 1.0和Stomp 1.1协议 主题和队列 队列浏览器 主题持久订阅 镜像队列 可靠的消息传递 消
Apollo Client 是一个全功能的 GraphQL 客户端,用于 React 、Angular 的交互。允许你轻松通过 GraphQL 获取数据并构建 UI 组件。
Glimmer Apollo: Ember and Glimmer integration for Apollo Client. Documentation Visit glimmer-apollo.com to read the docs. Compatibility Apollo Client v3.0 or above GlimmerX v0.6 or above Node.js v12 o
Apollo Angular Apollo Angular allows you to fetch data from your GraphQL server and use it in building complex and reactive UIs using the Angular framework. Apollo Angular may be used in any context t
apollo-link ⚠️ THIS PROJECT HAS BEEN DEPRECATED ⚠️ The Links in this repo have been migrated to the apollo-client project (as of >= @apollo/client@3.0.0). Please refer to the Apollo Client migration g