Installing and publishing packages

How to install and publish packages

These steps assume you already have an account and have authenticated to your registry. If don’t have an account, read the Getting started to get up and running in less than a minute.

Installing packages from your private registry

To install npm packages using npm, see the example below.

The Bytesafe web console will show all package dependencies which are downloaded and stored in your registry default.

npm --registry 'https://example.bytesafe.dev/r/default/' install <package>

To add npm packages using yarn, see the example below.

The Bytesafe web console will show all package dependencies which are downloaded and stored in your registry default.

yarn --registry 'https://example.bytesafe.dev/r/default/' add <package>

To add npm packages using pnpm, see the example below.

The Bytesafe web console will show all package dependencies which are downloaded and stored in your registry default.

pnpm add <package> --registry 'https://example.bytesafe.dev/r/default/' 

Publishing packages to your registry

Publish your npm packages with npm. If you would like to publish a package to your Bytesafe registry, look at the example below.

npm --registry 'https://example.bytesafe.dev/r/default/' publish <package>

Publish your npm packages with yarn. If you would like to publish a package to your Bytesafe registry, look at the example below.

yarn --registry 'https://example.bytesafe.dev/r/default/' publish <package>

Publish your npm packages with pnpm. If you would like to publish a package to your Bytesafe registry, look at the example below.

pnpm publish <package> --registry 'https://example.bytesafe.dev/r/default/'