@easyguide/stepper

0.9.12 • Public • Published

@easyguide/stepper

Camponents stepper ui

NPM JavaScript Style Guide

Install

npm install --save @easyguide/stepper

Usage

import React, {Component} from 'react'

import Stepper, {withStep} from '@easyguide/stepper'

const Step = withStep(({ previous, next, activeStep }) => (
  <section data-testid="step">
    <h1>{activeStep}</h1>
    <p>description</p>
    <button onClick={previous} data-testid="step-previous-button">
      previous
    </button>
    <button onClick={next} data-testid="step-next-button">
      next
    </button>
  </section>
))

class Example extends Component {
  render() {
    return (
      <Stepper>
        <Step stepName="step 1" />
        <Step stepName="step 2" />
      </Stepper>
    )
  }
}

License

MIT © iamtchelo

Readme

Keywords

none

Package Sidebar

Install

npm i @easyguide/stepper

Weekly Downloads

0

Version

0.9.12

License

MIT

Unpacked Size

13.3 kB

Total Files

6

Last publish

Collaborators

  • celso-henrique
  • wellyal
  • guilhermegregio
  • rafaellucio
  • iamtchelo
  • danicastilho