11.0.0 • Published 6 months ago

read-pkg-up v11.0.0

Weekly downloads
37,104,149
License
MIT
Repository
github
Last release
6 months ago

read-pkg-up

Read the closest package.json file

Why

Install

npm install read-pkg-up

Usage

import {readPackageUp} from 'read-pkg-up';

console.log(await readPackageUp());
/*
{
	packageJson: {
		name: 'awesome-package',
		version: '1.0.0',
		…
	},
	path: '/Users/sindresorhus/dev/awesome-package/package.json'
}
*/

API

readPackageUp(options?)

Returns a Promise<object>, or Promise<undefined> if no package.json was found.

readPackageUpSync(options?)

Returns the result object, or undefined if no package.json was found.

options

Type: object

cwd

Type: URL | string\ Default: process.cwd()

The directory to start looking for a package.json file.

normalize

Type: boolean\ Default: true

Normalize the package data.

Related

  • read-pkg - Read a package.json file
  • pkg-up - Find the closest package.json file
  • find-up - Find a file by walking up parent directories
  • pkg-conf - Get namespaced config from the closest package.json
conventional-changelog-core@yattho/gatsby-theme-rigitus@prisma/internals@oyvinmar-forks/cli@prisma/sdk@ismay/morpheus-cli@ismay/silkscreen-cli@ismay/synesthesia-cli@ismay/cutout-cli@storybook/addon-storyshots@storybook/test-runner@storybook/angulararchetype-library@fz6m/skncoarse-cli@teambit/legacyeasy-select-rn@g7fe/g7-scriptschinjowwchinjow@jvdx/eslint@jvdx/eslint-config-jvdxreact-native-bluetooth2killi8n-react-native-fast-imagepipihome@imbsky/validate-dependencies@tanahatas/satpam-dependenciesrn-send-sms@rock-kit/pkg-utils@awanisius/satpam-dependencies@icanpm/api-masterbappo-scripts@arisageha/react-lazyload@arisageha/react-lazyload-fixswift-package-installer@__escad-test/corelffg-scriptsws-scripts@martyncherry/eslint-config@almeidaa/ms@flexboard-dev/typescript-template@clipchamp/semantic-release-gitreact-native-template-rfbasecustom-ignite-bowsergsmlg-scriptsairscanairscan-example@njmaeff/node-build-core@njmaeff/node-build-ui-cli@njmaeff/node-gen-cli@njmaeff/node-release@njmaeff/sdk-publish@njmaeff/test-helpers@njmaeff/node-build-cli@njmaeff/node-build-plugin-tsbb-chatreact-native-esc-pos-sahaab@withonevision/omnihive@borisovart/atol-kkt-module@frxf/frxfwechaty-puppet-wechat4u-tps40-scriptseslint-config-refined@martynastell/eslint-configdeneme323112eslint-config-thedaviddiaseslint-config-japhy@darkobits/ts-unified@ntt_app/react-native-custom-notification@educationperfect/semantic-releasecovid-pk-vaccination-centres-parsereslint-config-remedy@temporg/pkg-utilsreact-native-covid-sdkpkg-discovery@jeremiergz/server-cli@kobionic/server-libgql_din_mod@thebespokepixel/xo-tidy@thebespokepixel/cordialbitgeteslint-config-typicalsuperchargednpm-s3react-native-thanh-toast-libraryrel-engagemutasi-bcads-actionscal-scripts@jttechnic/interpreter@thanhnguyen14797/react-native-thanh-toast-library@drivetribe/dd-trace@ez-fe/cli@ez-fe/helper@ez-fe/oopseslint-config-gorrioncthpb-plugin-socialhunh-beautify@olivervorasai/slidermysql-format
11.0.0

6 months ago

10.0.0

10 months ago

10.1.0

8 months ago

9.1.0

2 years ago

9.0.0

3 years ago

8.0.0

3 years ago

7.0.1

4 years ago

7.0.0

5 years ago

6.0.0

5 years ago

5.0.0

5 years ago

4.0.0

6 years ago

3.0.0

6 years ago

2.0.0

8 years ago

1.0.1

9 years ago

1.0.0

9 years ago