1.0.8 • Published 6 years ago

ndt-react-list v1.0.8

Weekly downloads
2
License
ISC
Repository
github
Last release
6 years ago

ndt-react-list

React list by ndt 💪

npm version

Installation

npm install --save ndt-react-list

Usage

Without text field

// example.js

import React from 'react'
import List from 'ndt-react-list'

const posts = [
  {
    id: 1,
    title: 'Create Apps with No Configuration',
  },
  {
    id: 2,
    title: 'Mixins Considered Harmful',
  },
]

const Example = () => (
  <div className="example">
    <List collection={posts} titleKey="title" />
  </div>
)

export default Example

With text field

// example.js

import React from 'react'
import List from 'ndt-react-list'

const posts2 = [
  {
    id: 1,
    title: 'Create Apps with No Configuration',
    text: 'text field 1'
  },
  {
    id: 2,
    title: 'Mixins Considered Harmful',
    text: 'text field 2'
  },
]

const Example = () => (
  <div className="example">
    <List collection={posts2} titleKey="title" textKey="text" />
  </div>
)

export default Example

Development

Development server for demo site

npm start

Storybook

npm run storybook

Test locally

In this package

npm link

Go to other project (package)

npm link ndt-react-list

to link this package locally

Publish demo site to github

npm run publish-demo
1.0.8

6 years ago

1.0.7

6 years ago

1.0.6

6 years ago

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago