{"id":13422375,"url":"https://github.com/nkbt/react-height","last_synced_at":"2025-09-21T06:51:14.516Z","repository":{"id":41565956,"uuid":"45242517","full_name":"nkbt/react-height","owner":"nkbt","description":"Component-wrapper to determine and report children elements height","archived":false,"fork":false,"pushed_at":"2025-02-27T12:16:06.000Z","size":57545,"stargazers_count":182,"open_issues_count":2,"forks_count":27,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-08-09T14:17:36.934Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nkbt.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-10-30T09:47:26.000Z","updated_at":"2025-03-04T14:51:50.000Z","dependencies_parsed_at":"2025-03-10T15:47:54.901Z","dependency_job_id":null,"html_url":"https://github.com/nkbt/react-height","commit_stats":null,"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"purl":"pkg:github/nkbt/react-height","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nkbt%2Freact-height","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nkbt%2Freact-height/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nkbt%2Freact-height/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nkbt%2Freact-height/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nkbt","download_url":"https://codeload.github.com/nkbt/react-height/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nkbt%2Freact-height/sbom","scorecard":{"id":690120,"data":{"date":"2025-08-11","repo":{"name":"github.com/nkbt/react-height","commit":"d034ae8b3d27139be5105a878b705d0a390c645b"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.1,"checks":[{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Code-Review","score":1,"reason":"Found 2/15 approved changesets -- score normalized to 1","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":-1,"reason":"internal error: error during branchesHandler.setup: internal error: githubv4.Query: Resource not accessible by integration","details":null,"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 21 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"63 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-968p-4wvh-cqc8","Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92","Warn: Project is vulnerable to: GHSA-whgm-jr23-g3j9","Warn: Project is vulnerable to: GHSA-93q8-gq69-wqmw","Warn: Project is vulnerable to: GHSA-fwr7-v2mv-hh25","Warn: Project is vulnerable to: GHSA-qwcr-r2fm-qrc7","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg","Warn: Project is vulnerable to: GHSA-pxg6-pf52-xh8x","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-w573-4hg7-7wgq","Warn: Project is vulnerable to: GHSA-6h5x-7c5m-7cr7","Warn: Project is vulnerable to: GHSA-rv95-896h-c2vc","Warn: Project is vulnerable to: GHSA-qw6h-vgh9-j6wx","Warn: Project is vulnerable to: GHSA-74fj-2j2h-c42q","Warn: Project is vulnerable to: GHSA-pw2r-vq6v-hr8c","Warn: Project is vulnerable to: GHSA-jchw-25xp-jwwc","Warn: Project is vulnerable to: GHSA-cxjh-pqwp-8mfp","Warn: Project is vulnerable to: GHSA-8mmm-9v2q-x3f9","Warn: Project is vulnerable to: GHSA-rc47-6667-2j5j","Warn: Project is vulnerable to: GHSA-c7qv-q95q-8v27","Warn: Project is vulnerable to: GHSA-78xj-cgh5-2h22","Warn: Project is vulnerable to: GHSA-2p57-rm9w-gvfp","Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h","Warn: Project is vulnerable to: GHSA-76p3-8jx3-jpfq","Warn: Project is vulnerable to: GHSA-3rfm-jhwj-7488","Warn: Project is vulnerable to: GHSA-hhq3-ff78-jv3g","Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv","Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3","Warn: Project is vulnerable to: GHSA-xvch-5gv4-984h","Warn: Project is vulnerable to: GHSA-qrpm-p2h7-hrv2","Warn: Project is vulnerable to: GHSA-mwcw-c2x4-8c55","Warn: Project is vulnerable to: GHSA-5rrq-pxf6-6jx5","Warn: Project is vulnerable to: GHSA-8fr3-hfg3-gpgp","Warn: Project is vulnerable to: GHSA-gf8q-jrpm-jvxq","Warn: Project is vulnerable to: GHSA-2r2c-g63r-vccr","Warn: Project is vulnerable to: GHSA-cfm4-qjh2-4765","Warn: Project is vulnerable to: GHSA-x4jg-mjrx-434g","Warn: Project is vulnerable to: GHSA-rp65-9cf3-cjxr","Warn: Project is vulnerable to: GHSA-76c9-3jph-rj3q","Warn: Project is vulnerable to: GHSA-9wv6-86v2-598j","Warn: Project is vulnerable to: GHSA-rhx6-c78j-4q9w","Warn: Project is vulnerable to: GHSA-7fh5-64p2-3v2j","Warn: Project is vulnerable to: GHSA-hrpp-h998-j3pp","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-m6fv-jmcg-4jfg","Warn: Project is vulnerable to: GHSA-76p7-773f-r4q5","Warn: Project is vulnerable to: GHSA-cm22-4g7w-348p","Warn: Project is vulnerable to: GHSA-5955-9wpr-37jh","Warn: Project is vulnerable to: GHSA-qq89-hq3f-393p","Warn: Project is vulnerable to: GHSA-f5x3-32g6-xq36","Warn: Project is vulnerable to: GHSA-4wf5-vphf-c2xc","Warn: Project is vulnerable to: GHSA-rqff-837h-mm52","Warn: Project is vulnerable to: GHSA-8v38-pw62-9cw2","Warn: Project is vulnerable to: GHSA-hgjh-723h-mx2j","Warn: Project is vulnerable to: GHSA-jf5r-8hm2-f872","Warn: Project is vulnerable to: GHSA-hc6q-2mpp-qw7j","Warn: Project is vulnerable to: GHSA-4vvj-4cpr-p986","Warn: Project is vulnerable to: GHSA-wr3j-pwj9-hqq6","Warn: Project is vulnerable to: GHSA-4v9v-hfq4-rm2v","Warn: Project is vulnerable to: GHSA-9jgg-88mc-972h","Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7","Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-22T02:08:15.571Z","repository_id":41565956,"created_at":"2025-08-22T02:08:15.571Z","updated_at":"2025-08-22T02:08:15.571Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":276204837,"owners_count":25602738,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-21T02:00:07.055Z","response_time":72,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-07-30T23:00:43.088Z","updated_at":"2025-09-21T06:51:14.484Z","avatar_url":"https://github.com/nkbt.png","language":"JavaScript","readme":"# react-height [![npm](https://img.shields.io/npm/v/react-height.svg?style=flat-square)](https://www.npmjs.com/package/react-height)\n\n[![CircleCI](https://img.shields.io/circleci/project/nkbt/react-height.svg?style=flat-square\u0026label=build)](https://circleci.com/gh/nkbt/react-height)\n\nComponent-wrapper to determine and report children elements height\n\n![React Height](./example/react-height.gif)\n\n\n## Goals\n\n- `react-height` keeps things simple, therefore it does not support nested height change, it only checks immediate children change\n- not based on specific browser APIs, so can be used in other environments too\n\n## Simple web demo\n\n[https://nkbt.github.io/react-height](https://nkbt.github.io/react-height)\n\n## Codepen demo\n\n[https://codepen.io/nkbt/pen/NGzgGb](https://codepen.io/nkbt/pen/NGzgGb?editors=101)\n\n## Installation\n\n### NPM\n\n```sh\nnpm install --save react-height\n```\n\n### yarn\n\n```sh\nyarn add react-height\n```\n\n### 1998 Script Tag:\n```html\n\u003cscript src=\"https://unpkg.com/react/umd/react.production.min.js\"\u003e\u003c/script\u003e\n\u003cscript src=\"https://unpkg.com/react-height/build/react-height.js\"\u003e\u003c/script\u003e\n(Module exposed as `ReactHeight`)\n```\n\n\n## Usage\n```js\nimport {ReactHeight} from 'react-height';\n\n\u003cReactHeight onHeightReady={height =\u003e console.log(height)}\u003e\n  \u003cdiv\u003eRandom content\u003c/div\u003e\n\u003c/ReactHeight\u003e\n```\n\n## Options\n\n\n### `onHeightReady`: PropTypes.func.isRequired\n\nCallback, invoked when height is measured (and when it is changed).\n\n### `getElementHeight`: PropTypes.func\n\nFunction to measure your element. It receives the element as argument and defaults to `el =\u003e el.clientHeight`.\n\n### `children`: PropTypes.node.isRequired\n\nOne or multiple children with static, variable or dynamic height.\n\n```js\n\u003cReactHeight onHeightReady={height =\u003e console.log(height)}\u003e\n  \u003cp\u003eParagraph of text\u003c/p\u003e\n  \u003cp\u003eAnother paragraph is also OK\u003c/p\u003e\n  \u003cp\u003eImages and any other content are ok too\u003c/p\u003e\n  \u003cimg src=\"nyancat.gif\" /\u003e\n\u003c/ReactHeight\u003e\n```\n\n\n### `hidden`: PropTypes.bool (default: false)\n\nReactHeight can render to null as soon as height is measured.\n\n```js\n\u003cReactHeight hidden={true} onHeightReady={height =\u003e console.log(height)}\u003e\n  \u003cdiv\u003eWill be removed from the DOM when height is measured\u003c/div\u003e\n\u003c/ReactHeight\u003e\n```\n\n### Pass-through props\n\nAll other props are applied to a container that is being measured. So it is possible to pass `style` or `className`, for example.\n\n```js\n\u003cReactHeight onHeightReady={height =\u003e console.log(height)}\n  style={{width: 200, border: '1px solid red'}}\n  className=\"myComponent\"\u003e\n\n  \u003cdiv\u003e\n    Wrapper around this element will have red border, 200px width\n    and `class=\"myComponent\"`\n  \u003c/div\u003e\n\u003c/ReactHeight\u003e\n```\n\n\n\n## Development and testing\n\nCurrently is being developed and tested with the latest stable `Node` on `OSX`.\n\nTo run example covering all `ReactHeight` features, use `yarn start`, which will compile `example/index.js`\n\n```bash\ngit clone git@github.com:nkbt/react-height.git\ncd react-height\nyarn install\nyarn start\n\n# then\nopen http://localhost:8080\n```\n\n## Tests\n\n```bash\n# to run ESLint check\nyarn lint\n\n# to run tests\nyarn test\n```\n\n## License\n\nMIT\n","funding_links":[],"categories":["UI Utilities","Uncategorized","UI Utilites"],"sub_categories":["Reporter","Uncategorized"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnkbt%2Freact-height","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnkbt%2Freact-height","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnkbt%2Freact-height/lists"}