tbg_props_to_state

2.0.0 • Public • Published

Props to State

How to use

Comp   = React.createClass

  getInitialState: -> 
    TransferToState(@props, 
      current_user: "options.current_user?",
      verification_status: "options.verification_status"
    )

If you also wish to set default state values

Comp   = React.createClass

  getInitialState: -> 
    TransferToState(@props,
      {
        current_user: "options.current_user?",
        verification_status: "options.verification_status"
      },
      {
        display: true
      }
    )

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 2.0.0
    0
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 2.0.0
    0
  • 1.0.0
    0

Package Sidebar

Install

npm i tbg_props_to_state

Weekly Downloads

0

Version

2.0.0

License

MIT

Last publish

Collaborators

  • samternent
  • adtaylor