npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

react-table-strap

v0.0.9

Published

A simple react table

Readme

react-table-strap

Install

npm

npm install react-table-strap

Dependencies

It is highly recommended to use below package as a dependency. Some functionality may not work if they are not used

  • bootstrap
  • react-bootstrap
  • @fortawesome/fontawesome-free
  • jquery
  • react
  • react-dom

ScreenShot

Usage

import TableStrap from 'react-table-strap';
 ...
// if remote pagination
state = {
    paginationOptions: {
        page: 1,
        sizePerPage: 10,
        totalSize: undefined,
    },
}
    
...

const data =[
    {
        id: 1,
        firstName: {first:"Sonni", second:" Baldo"},
        lastName: "Gabotti",
        email: "[email protected]",
        userName: "sgabotti0",
        gender: "Female",
        status: 0,
        dateOfBbirth: "10/14/1950",
        ipAddress: "251.237.126.210",
        type: 1,
        _userId: 1,
        _createdDate: "09/07/2016",
        _updatedDate: "05/31/2013"
    },
    {
        id: 2,
        firstName: {first:"Abie", second:"Yenn"},
        lastName: "Cowperthwaite",
        email: "[email protected]",
        userName: "acowperthwaite1",
        gender: "Male",
        status: 1,
        dateOfBbirth: "12/31/1998",
        ipAddress: "239.176.5.218",
        type: 1,
        _userId: 2,
        _createdDate: "03/18/2014",
        _updatedDate: "08/17/2016"
    }]
    
    const columns= [
            {
                dataField: "firstName",
                text: "User Name",
                formatter: (cell, row, rowIndex) => {
                    return <div className={"text-danger"}>{row.firstName.first + " " + row.lastName}</div>
                },
                filter: i18n.t('filtrele'),
                sort:true
            }, {
                dataField: "firstName.second",
                text: "Second Name",
                classes: 'align-middle text-right',
                style:{fontSize:"12px"},
                sort:true,
                collapsable:true //colomn collapse and hidden, it can be seen in popover
            }, {
                dataField: "email",
                text: "Email",
                hidden: !this.state.isEmailShown
            }, {
                dataField: "dateOfBbirth",
                text: "Date Of Birth",
            filter:true,
            dropDownFilter:[
                i18n.t('2000'),
                i18n.t('2001'),
                i18n.t('2002'),
                i18n.t('2003')],
            }
        ];

handleSelection = (row) => {
    this.setState({...this.state, selectedTableRow: row}); //row[0] if radioButton(isMulti={false}), row if checkbox(isMulti={true})
}


//if any extra info needed depends on a button
    const expandRow = {
        renderer: row => {
            return <Row className={"text-success d-inline-block "}>
               Some extra info which will be shown in overlay popup
            </Row>
        }
    
    }
...

//no remote pagiantion
<TableStrap data={data} columns={columns} keyField={"id"}
            isSelectable={true}
            isMulti={true}  //multiselection - checkbox
            filter
            isMultiFilter={true} //filter by any column
            selectRowOnClick={true} // if true you can select row as click on it. if false you should click on radio/checkbox
            rowStyle={{backgroundColor:"red"}}
            bodyClasses={"table-body-small"}
            headerClasses={"table-header "}
            noDataIndication={"No data found"}
            expandRow={expandRow}
/>

//if remote pagiantion
<TableStrap data={data} columns={columns} keyField={"id"}
            isSelectable={true}
            isMulti={true} 
            filter
            isMultiFilter={true} //filter by any column
            selectedRows={this.handleSelection}
            expandRow={expandRow}
            rowStyle={{backgroundColor:"red"}}
            bodyClasses={"table-body-small"}
            headerClasses={"table-header"}
            noDataIndication={"No data found"}
            selectRowOnClick={true} // if true you can select row by clicking on row. if false you should click on radio/checkbox
            remote  
            paginationOptions={this.state.paginationOptions}
            onTableChange={(paginationOpt, search) => this.onTableChange(paginationOpt, search)}
            
/>

...