How to use the uikit-react.Select.displayName function in uikit-react

To help you get started, we’ve selected a few uikit-react 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 stipsan / uikit-react / src / stories / Select.js View on Github external
// import Option from 'uikit-react/Select/Option'
// import Value from 'uikit-react/Select/Value'

import { storiesOf, action } from '@kadira/storybook'
import { cloneElement, Component, PropTypes } from 'react'
import { Select } from 'uikit-react'

// This is to work around: https://github.com/kadirahq/react-storybook-addon-info/issues/26#issuecomment-229029177
Select.displayName = 'Select'

class Form extends Component {
  static propTypes = {
    children: PropTypes.node.isRequired,
    defaultValue: PropTypes.any, // eslint-disable-line react/forbid-prop-types
  }
  static props = {
    defaultValue: null,
  }
  state = {
    value: this.props.defaultValue,
  }
  logChange = action('onChange')
  handleChange = (value) => {
    this.setState({ value })
    this.logChange(value)

uikit-react

UIkit components for use in React.

ISC
Latest version published 2 years ago

Package Health Score

42 / 100
Full package analysis