victory README

The project's README from github.com/FormidableLabs/victory. As one markdown file: README.md.

Victory — Formidable, We build the modern web an ecosystem of composable React components for building interactive data visualizations.

weekly downloads current version build status Maintenance Status

Victory

Contents

Getting started

  1. Add Victory to your project:
# npm
$ npm i --save victory
# or yarn
$ yarn add victory
  1. Add your first Victory component:
import React from "react";
import { render } from "react-dom";
import { VictoryPie } from "victory";

const PieChart = () => {
  return <VictoryPie />;
};

render(<PieChart />, document.getElementById("app"));
  1. VictoryPie component will be rendered, and you should see:

pie


Requirements

Projects using Victory should also depend on React. As of [email protected] Victory requires React version 16.3.0 or above

Victory Native

Victory Native shares most of its code with Victory, and has a nearly identical API! To learn more, check out the Victory Native package README.

Contributing

Please see the Contributing guide.

Maintenance Status

Active: Formidable is actively working on this project, and we expect to continue to work for the foreseeable future. Bug reports, feature requests and pull requests are welcome.

victory (FormidableLabs/victory)

Searching Database…

11.2K ·GitHub
这是什么?Victory 是一组可组合的 React 组件,用于构建交互式数据可视化,例如图表和曲线图。
这是一个直接放进 React 应用里使用的组件库,还是更大的东西?它是一组独立的 React 组件(如 VictoryPie、VictoryChart 等),你可以把它们组合在一起使用,而不是一个完整的框架。另有一个配套包 Victory Native,它在 iOS 和 Android 上的 React Native 中使用,API 几乎相同。
我该如何把它添加到项目中?将 victory 包添加到你的项目中,然后导入并渲染一个组件,例如 VictoryPie,即可看到它的效果。
我需要特定版本的 React 吗?需要,你的项目必须依赖 React 16.3.0 或更高版本。
如果我想在移动端使用,是否就是完全相同的包?不是。对于 React Native 应用,你需要使用单独的 Victory Native 包;它的大部分代码和 API 与 Victory 相同,但作为独立的包进行维护。
这些图表具体可以在哪里渲染?在网页中配合 React 使用;在 iOS/Android 应用中,则通过 React Native 配合 Victory Native 使用。
我可以不先搭建项目就试用 Victory 吗?可以,项目页面中链接了一个代码沙盒,你可以直接在浏览器中试验 Victory 的所有组件。
这个项目还在积极维护吗?是的,Formidable 表示正在积极开发 Victory,并计划继续维护,包括处理错误报告和功能请求。
Victory 提供哪些类型的图表?它提供了一组可组合的图表基础组件,例如 VictoryPie 和 VictoryChart,可以组合起来构建自定义的数据可视化。
Size
64.1 MB
Stars
11.2K
Age
11y
Commits · 90 Days