{"library":"find-and-require-package-json","type":"library","category":null,"description":"This TypeScript module, `find-and-require-package-json`, provides a robust and type-safe function to programmatically locate, read, and parse a `package.json` file. It operates by starting from a specified directory and intelligently traversing upwards through parent directories until a `package.json` file is found or the root is reached. Currently at version 0.9.1, it is considered stable but, as a pre-1.0 release, it may introduce minor breaking changes in future minor versions. Its primary utility lies in build systems, CLI tools, and runtime environments where dynamically discovering project metadata is essential. Unlike simple `require('./package.json')` which is path-dependent, this library offers a flexible search mechanism, making it ideal for monorepos or complex project structures where the current working directory might not always contain the desired `package.json`. It ships with full TypeScript types, enhancing developer experience and compile-time safety.","language":"javascript","status":"active","version":"0.9.1","tags":["javascript","typescript"],"last_verified":"Wed May 27","install":[{"cmd":"npm install find-and-require-package-json","imports":["import { findAndRequirePackageJson } from 'find-and-require-package-json';","import { findAndRequirePackageJsonSync } from 'find-and-require-package-json';","import type { PackageJson } from 'find-and-require-package-json';"]},{"cmd":"yarn add find-and-require-package-json","imports":[]},{"cmd":"pnpm add find-and-require-package-json","imports":[]}],"homepage":null,"github":"https://github.com/constructive-io/dev-utils","docs":null,"changelog":null,"pypi":null,"npm":"https://www.npmjs.com/package/find-and-require-package-json","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"18–22","success_rate":0,"avg_install_s":null,"avg_import_s":null,"wheel_type":null},"url":"https://checklist.day/v1/registry/find-and-require-package-json/compatibility"}}