Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@lerna/bootstrap

Package Overview
Dependencies
Maintainers
2
Versions
128
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@lerna/bootstrap

Link local packages together and install remaining package dependencies

  • 3.4.1
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
433K
decreased by-13.6%
Maintainers
2
Weekly downloads
 
Created

What is @lerna/bootstrap?

@lerna/bootstrap is a part of the Lerna monorepo management toolset. It is used to install and link dependencies for a multi-package repository, ensuring that all inter-package dependencies are properly resolved and symlinked.

What are @lerna/bootstrap's main functionalities?

Install dependencies

This feature installs all the dependencies for the packages in the monorepo. It uses the npm client and hoists common dependencies to the root node_modules directory.

const { bootstrap } = require('@lerna/bootstrap');

bootstrap({
  cwd: process.cwd(),
  npmClient: 'npm',
  hoist: true
}).then(() => {
  console.log('Dependencies installed and linked');
});

Link local packages

This feature links local packages together, ensuring that inter-package dependencies are resolved using symlinks. This is useful for development as changes in one package are immediately reflected in dependent packages.

const { bootstrap } = require('@lerna/bootstrap');

bootstrap({
  cwd: process.cwd(),
  npmClient: 'npm',
  hoist: true
}).then(() => {
  console.log('Local packages linked');
});

Run lifecycle scripts

This feature runs specified lifecycle scripts (e.g., prepublish, postinstall) for all packages in the monorepo. This ensures that any necessary build steps or other setup tasks are performed.

const { bootstrap } = require('@lerna/bootstrap');

bootstrap({
  cwd: process.cwd(),
  npmClient: 'npm',
  hoist: true,
  scripts: ['prepublish', 'postinstall']
}).then(() => {
  console.log('Lifecycle scripts executed');
});

Other packages similar to @lerna/bootstrap

Keywords

FAQs

Package last updated on 04 Oct 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc