es6-set-proptypes
DefinitelyTyped icon, indicating that this package has TypeScript declarations provided by the separate @types/es6-set-proptypes package

1.0.0 • Public • Published

es6-set-proptypes

React PropTypes for ES6 Sets and compatible interfaces.

Build Status

Tested with native Set (in Node), babel-polyfill, es6-set, and Immutable.Set. Includes an isRequired property to work the same way as React.PropTypes.

Usage

import React, { Component, PropTypes } from 'react';
import setType from 'es6-set-proptypes';

export default class UniqueList extends Component {
  static propTypes = {
    header: PropTypes.string,
    items: setType.isRequired,
    hiddenItems: setType
  };

  render() {
    return (
      ...
    );
  }
}

Package Sidebar

Install

npm i es6-set-proptypes

Weekly Downloads

317

Version

1.0.0

License

ISC

Last publish

Collaborators

  • mlendale