compare-props
TypeScript icon, indicating that this package has built-in type declarations

0.0.15 • Public • Published

🚀
compare-props



npm i compare-props
Or
yarn add compare-props



Checking if props change with React.memo in React components.

Test Data: link

Usage

import React from "react"
import { compareProps } from "compare-props"

type DemoProps = {
  name: string,
}

export const Demo: React.FunctionComponent<DemoProps> = React.memo(
  ({ name }: DemoProps) => {
    return <div>Title: {name}</div>
  },
  compareProps
)

Readme

Keywords

Package Sidebar

Install

npm i compare-props

Weekly Downloads

57

Version

0.0.15

License

MIT

Unpacked Size

38.1 kB

Total Files

14

Last publish

Collaborators

  • momocoding