How to use the g2-mobile.ready function in g2-mobile

To help you get started, we’ve selected a few g2-mobile examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github alibaba / rax / packages / rax-charts / src / charts / weexGM.js View on Github external
import GM from 'g2-mobile';

let _context;
const _chartRender = GM.Chart.prototype.render;

GM.Chart.prototype.render = function() {
  _chartRender.call(this);
  _context.render();
};

GM.ready = function(context) {
  _context = context;
};

export default GM;

g2-mobile

The mobile version of g2

MIT
Latest version published 7 years ago

Package Health Score

67 / 100
Full package analysis