我有一个自定义的storm-react-diagram节点:
this.engine.registerNodeFactory(new ExampleNodeFactory());
const node2 = new ExampleNodeModel();
const port2 = node2.addPort( new ExamplePortModel("left") );我在Widget中的render方法如下所示:
render() {
return (
<div className="grid-node" style={{textAlign: 'center', width: '140px'}}>
<ExampleIcon style={{width: '80px', height: '80px', position: 'relative', color: '#0d84b7'}} />
</div>
);
}我的问题是:是否可以将react-vis仪表图元素添加到我的自定义节点中?
结果将是渲染的Node,其中react-vis gauge元素围绕在Node周围。
不知道该怎么做……
发布于 2018-02-10 16:53:14
我认为您可能没有为您的用例使用正确的库。React-vis是一个在浏览器上使用react进行html和dom操作的库。听起来你想要的是一个反应原生的应用程序,我建议你使用类似于胜利原生(https://github.com/FormidableLabs/victory-native)的东西。
https://stackoverflow.com/questions/48705941
复制相似问题