{"name":"@rc-component/resize-observer","version":"1.0.0","keywords":["react","react-component","react-resize-observer","resize-observer"],"license":"MIT","_id":"@rc-component/resize-observer@1.0.0","maintainers":[{"name":"zombiej","email":"smith3816@gmail.com"},{"name":"afc163","email":"afc163@gmail.com"},{"name":"madccc","email":"1075746765@qq.com"},{"name":"peachscript","email":"scdzwyxst@gmail.com"}],"homepage":"https://react-component.github.io/resize-observer","bugs":{"url":"http://github.com/react-component/resize-observer/issues"},"cnpm":{"mode":"npm"},"dist":{"shasum":"93486fc12e95318eddd2d4e7a863b274e5a2a44f","tarball":"http://registry-npm.ywwl.com/@rc-component/resize-observer/download/@rc-component/resize-observer-1.0.0.tgz","fileCount":21,"integrity":"sha512-inR8Ka87OOwtrDJzdVp2VuEVlc5nK20lHolvkwFUnXwV50p+nLhKny1NvNTCKvBmS/pi/rTn/1Hvsw10sRRnXA==","signatures":[{"sig":"MEUCIQDxYhmTCR/Mkw6vePSf7frhYQe0d5S5x3l6zyTh/zX6JgIgPz2t6Z8LlXxIsZroG5XtSr5BNImw0rM6BgOTZcougkA=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":33396,"size":7446,"noattachment":false,"key":"/@rc-component/resize-observer/-/@rc-component/resize-observer-1.0.0.tgz"},"main":"./lib/index","tnpm":{"mode":"npm"},"types":"./lib/index.d.ts","module":"./es/index","gitHead":"42c60bf21798fc3d8c65592ec5e6af1a1c6e56cb","scripts":{"lint":"eslint src/ --ext .ts,.tsx,.jsx,.js,.md","test":"rc-test","build":"dumi build","start":"dumi dev","deploy":"UMI_ENV=gh npm run build && gh-pages -d dist","compile":"father build && lessc assets/index.less assets/index.css","prepare":"dumi setup","coverage":"rc-test --coverage","gh-pages":"npm run deploy","prettier":"prettier --write \"**/*.{ts,tsx,js,jsx,json,md}\"","now-build":"npm run build","postpublish":"npm run gh-pages","prepublishOnly":"npm run compile && rc-np"},"_npmUser":{"name":"zombiej","email":"smith3816@gmail.com"},"repository":{"url":"git+ssh://git@github.com/react-component/resize-observer.git","type":"git"},"_npmVersion":"10.8.2","description":"Resize observer for React","directories":{},"_nodeVersion":"22.5.1","dependencies":{"classnames":"^2.2.1","@rc-component/util":"^1.2.0"},"_hasShrinkwrap":false,"devDependencies":{"dumi":"^2.0.0","glob":"^7.1.6","less":"^4.1.3","react":"^16.0.0","enzyme":"^3.0.0","father":"^4.0.0","cheerio":"1.0.0-rc.12","rc-test":"^7.0.15","gh-pages":"^6.1.0","prettier":"^3.2.5","coveralls":"^3.0.6","cross-env":"^7.0.2","react-dom":"^16.0.0","@types/jest":"^29.5.10","@types/react":"^18.0.28","pretty-quick":"^4.0.0","@umijs/fabric":"^2.0.9","enzyme-to-json":"^3.4.0","@rc-component/np":"^1.0.0","@types/react-dom":"^18.0.11","regenerator-runtime":"^0.14.0","@testing-library/react":"^12.1.5","enzyme-adapter-react-16":"^1.15.6","@rc-component/father-plugin":"^2.0.2"},"peerDependencies":{"react":">=16.9.0","react-dom":">=16.9.0"},"_npmOperationalInternal":{"tmp":"tmp/resize-observer_1.0.0_1737604739806_0.00999835182572606","host":"s3://npm-registry-packages-npm-production"},"readme":"# rc-resize-observer\n\n[![NPM version][npm-image]][npm-url] [![dumi](https://img.shields.io/badge/docs%20by-dumi-blue?style=flat-square)](https://github.com/umijs/dumi) [![build status][github-actions-image]][github-actions-url] [![Codecov][codecov-image]][codecov-url] [![npm download][download-image]][download-url]\n\n[npm-image]: http://img.shields.io/npm/v/rc-resize-observer.svg?style=flat-square\n[npm-url]: http://npmjs.org/package/rc-resize-observer\n[github-actions-image]: https://github.com/react-component/resize-observer/workflows/CI/badge.svg\n[github-actions-url]: https://github.com/react-component/resize-observer/actions\n[codecov-image]: https://img.shields.io/codecov/c/github/react-component/resize-observer/master.svg?style=flat-square\n[codecov-url]: https://codecov.io/gh/react-component/resize-observer/branch/master\n[download-image]: https://img.shields.io/npm/dm/rc-resize-observer.svg?style=flat-square\n[download-url]: https://npmjs.org/package/rc-resize-observer\n\nResize observer for React.\n\n## Live Demo\n\nhttps://resize-observer-react-component.vercel.app/\n\n## Install\n\n[![rc-resize-observer](https://nodei.co/npm/rc-resize-observer.png)](https://npmjs.org/package/rc-resize-observer)\n\n## Usage\n\n```js\nimport ResizeObserver from 'rc-resize-observer';\nimport { render } from 'react-dom';\n\nrender(\n  <ResizeObserver\n    onResize={() => {\n      console.log('resized!');\n    }}\n  >\n    <textarea />\n  </ResizeObserver>,\n  mountNode,\n);\n```\n\n## API\n\n| Property | Type                        | Default | Description                     |\n| -------- | --------------------------- | ------- | ------------------------------- |\n| disabled | boolean                     | false   |                                 |\n| onResize | ({ width, height }) => void | -       | Trigger when child node resized |\n\n## Development\n\n```\nnpm install\nnpm start\n```\n\n## License\n\nrc-resize-observer is released under the MIT license.\n","publish_time":1737604739979,"_cnpm_publish_time":1737604739979,"dist-tags":{"latest":"1.1.2"}}