@instructure/ui-prop-types
TypeScript icon, indicating that this package has built-in type declarations

9.0.1 • Public • Published

category: packages

ui-prop-types

npm  MIT License  Code of Conduct

A collection of custom prop type validators.

Functions

The ui-prop-types package contains the following:

Installation

npm install @instructure/ui-prop-types

Usage

import React from 'react'
import PropTypes from 'prop-types'

import { Children, controllable } from '@instructure/ui-prop-types'

class MyComponent extends React.Component {
  static propTypes = {
    children: Children.oneOf([SomeOtherComponent, AnotherComponent])
    selected: controllable(PropTypes.bool, 'onSelect'),
    onSelect: PropTypes.func
  }
  ...
}

/@instructure/ui-prop-types/

    Package Sidebar

    Install

    npm i @instructure/ui-prop-types

    Weekly Downloads

    29,354

    Version

    9.0.1

    License

    MIT

    Unpacked Size

    293 kB

    Total Files

    72

    Last publish

    Collaborators

    • bpjatacsuk
    • ajmal-esa
    • razorsh4rk
    • david.wenzlick.inst
    • robinkuss64
    • ardena
    • jcflow
    • jguardadom
    • jdewar
    • xcudder
    • ericsaupe
    • joyenjoyer
    • omarpr
    • cguanzon-inst
    • sarahgerard
    • jacksonhowe
    • jakeoeding
    • camray
    • cjs118
    • matyas.szabo
    • herrtopi
    • angela.gomba
    • kyler-instructure
    • instuici
    • eschiebel
    • maths22
    • jcrystal
    • skacsmark
    • itadmins
    • quizzesuici
    • instructure-toolsmiths-service-user
    • aogata-inst
    • instout