Coder Social home page Coder Social logo

mini-program-f2-demos's Introduction

支付宝小程序 F2 图表 demo

支付宝小程序端的 F2 图表 demo,微信小程序详见 wx-f2

如何使用

支付宝开发者工具(最新版)中打开,然后在项目根目录下安装 '@antv/my-f2' 模块。

npm install @antv/my-f2

也可以直接使用本地的 my-f2.js,在 ./lib/ 目录下。

说明

  1. my-f2 GitHub 地址:my-f2
  2. 如果项目对代码大小有要求,可以使用按需加载模块,只引入需要的模块,参加折线图 demo: pages/charts/line/index.js
import F2 from '@antv/my-f2/lib/core'; // 必须引入
require('@antv/f2/lib/geom/line'); // 只引入折线图
require('@antv/f2/lib/scale/time-cat'); // 时间类型的度量
const Tooltip = require('@antv/f2/lib/plugin/tooltip'); // 引入 tooltip 插件

如何进行按需加载,请参见:https://www.yuque.com/antv/f2/require-on-demand

mini-program-f2-demos's People

Contributors

simaq avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

mini-program-f2-demos's Issues

F2的性能对比

大神,我这边对比了一下F2在wx小程序和支付宝小程序上面的FPS,发现大部分情况下支付宝上的性能要优于wx小程序哦,不知道你们之前有对比过吗?

在支付宝/钉钉小程序中添加饼图的点击交互无效

这个demo里没有wx-f2中的pie-select示例,参照wx-f2中的交互,添加了一段代码,但是没有效果,
请问该如何在钉钉小程序中实现点击交互

chart.interaction('pie-select', {
    cancelable: false, // 不允许取消选中
    animate: {
      duration: 1000,
      easing: 'backOut'
    },
    onEnd(ev) {
      console.log('确实被点击了');
    }
  });

跑不起来

跑步起来啊 怎么搞
Error: Module parse failed: Unexpected character '�' (16:0)
You may need an appropriate loader to handle this file type.
(Source code omitted for this binary file)
at Object../node_modules/@antv/my-f2/lib/core.js (index.worker.js?t=1559122988639:238)
at webpack_require (bootstrap:19)
at Object../pages/charts/line/index.js (index.js:3)
at webpack_require (bootstrap:19)
at success (index$.worker.js:22)
at n (af-appx.worker.ide.min.js:24)
at r (af-appx.worker.ide.min.js:24)
at zs.bootstrapApp (af-appx.worker.ide.min.js:24)
at Object../.tea/entryFiles-development/index$.worker.js (index$.worker.js:38)
at webpack_require (bootstrap:19)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.