react-dummy-json

1.0.4 • Public • Published

react-dummy-json

A ReactJS hook to get the dummy json data.

How to use it?

You can use the project in this way:

Install

# with npm
npm i react-dummy-json

# with yarn
yarn add react-dummy-json

Usage

  • Import the package in your app:
import {
  useUsers,
  usePost,
  useComment,
  useCart,
  useProduct,
  useTodo,
  useQuotes,
  useRecipe,
  useDecoration,
  useFragrance,
  useAutomotive,
  useFurniture,
  useGroceries,
  useLaptop,
  useLighting,
  useMotorcycle,
  usePhone,
  useSkincare,
  useSunglass,
  useTops,
  useBags,
  useDress,
  useJewellery,
  useShoes,
  useWatch,
} from "react-dummy-json";
  • Get the dummy json data from the hooks:
const data = useUsers();

Package Sidebar

Install

npm i react-dummy-json

Weekly Downloads

0

Version

1.0.4

License

ISC

Unpacked Size

6.68 kB

Total Files

3

Last publish

Collaborators

  • saurabh-singh