搜索插件、代码仓与 APP 分类

插件详情v0.6.1

ferry_store

Ferry GraphQL 客户端的默认存储

AndroidiOSWebmacOSWindowsLinux
近 30 天下载
7.2万
喜欢数
2
Pub 分数
130

安装插件

flutter pub add ferry_store

插件介绍

基于插件公开信息、社区数据与项目使用情况整理的选型参考。

Ferry Store 是 Ferry GraphQL 客户端的默认状态管理解决方案,旨在高效管理并缓存 Flutter 应用中的 GraphQL 查询结果。它与 Ferry 无缝集成,提供响应式、类型安全的存储,可同步数据至服务器,支持乐观更新,并处理订阅。专为性能和开发者体验而打造,通过减少样板代码并确保跨平台的一致性,简化了 GraphQL 驱动应用中的状态处理。

适合场景

  • 管理缓存的 GraphQL 查询结果
  • 通过订阅处理实时更新
  • 乐观的 UI 更新
  • 跨平台 GraphQL 状态管理
  • 同步本地状态与服务器数据

主要特点

  • 内置缓存层
  • 类型安全的状态管理
  • 支持乐观更新
  • 实时订阅处理
  • 与Ferry客户端无缝集成

适合对象

  • 使用 Ferry GraphQL 客户端的 Flutter 应用
  • 需要高效数据同步的应用程序
  • 寻求 GraphQL 状态最小样板的开发人员
  • 针对多个平台的项目
  • 优先考虑反应式 UI 模式的团队

使用建议

  • 需要 Ferry GraphQL 客户端
  • 仅限在Ferry生态系统外有限独立使用
  • 可能需要学习与Ferry相关的模式
  • 不适用于非GraphQL状态管理
  • 最佳搭配 Ferry 生成的代码

原始 README

以下为关联源码仓库的 README 原文快照,最新内容请访问源码仓库。

A simple, powerful GraphQL Client for Flutter and Dart

MIT License PRs Welcome Watch on GitHub Star on GitHub Watch on GitHub Discord

Documentation 📖

Features

  1. ✅ Fully Typed: work faster and safer with compile time checks and IDE autocomplete, including fully typed Cache reads and writes.
  2. 🔄 Built-In Code Generators: automatically generated immutable data classes for all your GraphQL Operations and Fragments, based on your schema.
  3. 🌐 Customizable Network Interface: highly customizable network interface using gql_link, allowing you to compose and extend Links.
  4. ✨ Normalized Optimistic Cache: keep data in sync with cache normalization and update your UI instantly with optimistic data.
  5. 💾 Multiple Data Stores: extensible Store interface with built-in MemoryStore and HiveStore (which uses hive for offline persistence).
  6. 📄 Refetch & Pagination: easily update responses with new data or combine multiple responses, allowing for seamless pagination.
  7. 📱 Flutter Widgets: Widgets for Queries, Mutations, and Subscriptions, available out of the box.
  8. 🧈 Smooth: Run queries in a separate Isolate to free up resources on the UI thread

Packages

This repo is a monorepo for ferry and related packages.

Pub Package Description
version package:ferry Stream-based GraphQL Client
version package:ferry_cache Normalized, strongly typed, optimistic cache
version package:ferry_exec Strongly typed GraphQL execution interface
version package:ferry_flutter Flutter Widgets for GraphQL Operations
version package:ferry_generator Dart Type Generator for GraphQL Operations
version package:ferry_store Data Persistence for ferry's cache
version package:ferry_hive_store Hive implementation of ferry_store
version package:normalize Normalization / denormalization of GraphQL data

所属分类

依赖

依赖清单 2 项

源码仓库

使用此插件的项目

暂无相关数据。