API Playground
Components to create playgrounds for APIs easily.
Example Playground
import React from 'react';import ReactDOM from 'react-dom';import compose applyMiddleware createStore from 'redux';import logger Playground from 'api-playground';import MyComponentExample from './myComponentExample'; let reduxStore = ; let config = example: 'hello' ; ReactDOM;
Example Component
import React PropTypes Component from 'react';import PlaygroundComponent View Section Ui from 'api-playground'; @PlaygroundComponent static contextTypes = store: PropTypesobject ; static subscribe = 'reduxStateKey'; { thisrefsmodal; }; { }; actions = addItem: thisaddItem removeItem: thisremoveItem ; { return <View> <Section.Items = = = /> <Section> <Section.Param ="Quantity" =/> </Section> <Section> <Section.Request ="request"/> </Section> <Ui.Modal ="modal"> <Section.Form ="Item" = = /> </Ui.Modal> </View> ; } ;