Relay

Relay 是构建数据驱动的React应用程序的JavaScript框架。(Relay is a JavaScript framework for building data-driven React applications. )

  • 所有者: facebook/relay
  • 平台:
  • 許可證: MIT License
  • 分類:
  • 主題:
  • 喜歡:
    0
      比較:

Github星跟蹤圖

Relay 是构建数据驱动的React应用程序的JavaScript框架。

  • 声明式:不再使用命令式API与数据存储进行通信。 只需使用GraphQL声明您的数据需求,并让Relay 知道如何以及何时获取数据。
  • 托管:查询依靠他们的意见旁边,所以你可以很容易地理解你的应用程序。Relay 将查询集中到高效的网络请求中,仅获取所需的内容。
  • 突变:Relay 允许您使用GraphQL突变来变换客户端和服务器上的数据,并提供自动数据一致性,乐观更新和错误处理。
Relay Modern 是继电器的新版本,从头开始,更易于使用,更可扩展,最重要的是能够提高移动设备的性能。 Relay Modern通过静态查询和提前的代码生成来实现。
您可以增加转换现有的Relay 应用程序,或使用Relay Modern启动新的应用程序。

概覽

名稱與所有者facebook/relay
主編程語言Rust
編程語言JavaScript (語言數: 8)
平台
許可證MIT License
發布數85
最新版本名稱v16.2.0 (發布於 2024-01-23 11:34:56)
第一版名稱v0.1.0 (發布於 )
創建於2015-08-10 22:09:16
推送於2024-04-25 23:13:55
最后一次提交
星數18.2k
關注者數331
派生數1.8k
提交數9.6k
已啟用問題?
問題數2206
打開的問題數523
拉請求數111
打開的拉請求數136
關閉的拉請求數2201
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?

Relay Build Status npm version

Relay is a JavaScript framework for building data-driven React applications.

  • Declarative: Never again communicate with your data store using an imperative API. Simply declare your data requirements using GraphQL and let Relay figure out how and when to fetch your data.
  • Colocation: Queries live next to the views that rely on them, so you can easily reason about your app. Relay aggregates queries into efficient network requests to fetch only what you need.
  • Mutations: Relay lets you mutate data on the client and server using GraphQL mutations, and offers automatic data consistency, optimistic updates, and error handling.

See how to use Relay in your own project.

Example

The relay-examples repository contains an implementation of TodoMVC. To try it out:

git clone https://github.com/relayjs/relay-examples.git
cd relay-examples/todo
yarn
yarn build
yarn start

Then, just point your browser at http://localhost:3000.

Contribute

We actively welcome pull requests, learn how to contribute.

Users

We have a community-maintained list of people and projects using Relay in production.

License

Relay is MIT licensed.

去到頂部