Narcissistic, Perfectly Modest

    shinkansen-gears

    1.0.26 • Public • Published

    shinkansen-gears

    Shinkansen Gears

    Gears implements React + React Router navigation components for Zashiki Karakuri.

    Usage

    import {
      Gears
    } from 'shinkansen-gears'

    Gears exposes the props reverse, forward, and pattern.

    These props are optional. If no props are given then Gears will render null.

    Gears depends on a peer of Shinkansen Rails to transform the props reverse and forward into <Link /> components for React Router. (The prop pattern describes how reverse and forward should be transformed.)

    import React from 'react'
    import PropTypes from 'prop-types'
    
    export class Gears extends React.Component { }
    
    Gears.propTypes = {
      reverse: PropTypes.shape({
        alpha: PropTypes.string,
        omega: PropTypes.string
      }),
      forward: PropTypes.shape({
        alpha: PropTypes.string,
        omega: PropTypes.string
      }),
      pattern: PropTypes.string
    }

    See also

    Install

    npm i shinkansen-gears

    DownloadsWeekly Downloads

    41

    Version

    1.0.26

    License

    MIT

    Unpacked Size

    19.6 kB

    Total Files

    14

    Last publish

    Collaborators

    • modernpoacherlimited
    • jonathanperry