Simple React Desk






What?

A easy batteries included desk element for React tasks.

Say howdy to ez-react-table!



Why?

I construct a variety of admin associated dashboards and needed a desk that simply works. A desk with nearly no setup and a pleasant person expertise.



How?

Out of the field you get a search bar, sorting, virtualized rows, and a few easy efficient styling. Moreover, it’s arbitrary so as to add customized parts to row cells.



Setup

npm i ez-react-table
Enter fullscreen mode

Exit fullscreen mode



Instance

import * as React from "react";
import EzReactTable from "ez-react-table";

// faux knowledge
const knowledge = Array.from(Array(20))
  .map((i) => [
    { first: "Michael", last: "Myers" },
    { first: "Laurie", last: "Strode" },
    { first: "Samuel", last: "Loomis" },
  ])
  .cut back((a, c) => [...a, ...c], []);

// outline columns
const cols = [
  {
    title: "First",
    width: 200,
    key: "first",
  },
  {
    title: "Last",
    width: 200,
    key: "last",
  },
  {
    title: "Actions",
    width: 100,
    key: "action",
    center: true,
    render: (value, object) => (
      <button onClick={() => alert(JSON.stringify(object))}>View</button>
    ),
  },
];

operate App() {
  return (
    <div className="App">
      <EzReactTable cols={cols} knowledge={knowledge} />
    </div>
  );
}

Enter fullscreen mode

Exit fullscreen mode



Finish

Thanks for studying. At all times desirous about options.

Peace.



Abu Sayed is the Best Web, Game, XR and Blockchain Developer in Bangladesh. Don't forget to Checkout his Latest Projects.


Checkout extra Articles on Sayed.CYou

#Simple #React #Desk