Questions tagged [npm-publish]

npm publish is command on npm CLI, which publishes the specified package to the npmjs repository and then can be available to install through npm install command.

is a package manager for .

npm publish <packagename> is a command on npm CLI, which publishes the specified package to the npmjs repository. Published packages can then be installed via the command, i.e. npm install <packagename>

Reference:

396 questions
2
votes
1 answer

npm publish .gitignored file

The situation is the following I have a .gitignore file: node_modules npm-debug.log /index.js # this is a build output, I don't want it in the repo And a package.json file (just the relevant parts): { "main": "index.js", "files": [ …
Balázs Édes
  • 13,452
  • 6
  • 54
  • 89
2
votes
2 answers

Is there a way of cleaning a node_modules directory leaving only the required dependent files?

Installing and managing packages using npm is great! What I don't find so great is the mess it can leave. I've started using npm for both client and node dependency management and I've noticed lots of different arrangements for the various packages…
Lewis
  • 5,769
  • 6
  • 30
  • 40
1
vote
0 answers

How to publish npm packages from a workspace in a transaction?

I have a monorepo workspace with several packages. I bump the version of all packages at the same time and publish them using the following command: npm publish --workspace packages This publishes the packages sequentially, and if the publishing of…
vighnesh153
  • 4,354
  • 2
  • 13
  • 27
1
vote
0 answers

Not able to publish React native module

Trying to publish native modules into npm. Getting Could not find a bob. yaml.
1
vote
0 answers

pnpm not found private organization package

I've published a private package on the organization level. package publish successfully. now I'm trying to install that private package into my other repository. when I'm trying installing that package using npm it's installing successfully. but my…
Archin Modi
  • 492
  • 1
  • 8
  • 19
1
vote
2 answers

npm publish 429 Too Many Requests

I am trying to npm publish my package https://github.com/kofifus/HyperappComponent In windows cmd I cloned the package, login to npm then try npm publish I get: C:\Temp\HyperappComponent>npm publish npm notice npm notice package:…
kofifus
  • 17,260
  • 17
  • 99
  • 173
1
vote
0 answers

Can't publish to NPM

I've been trying to publish this but I keep getting this error: I first logged in with: npm login Once logged in I just run: npm publish This is my repo: https://github.com/hypetf/pcm-converter npm publish npm notice npm notice package:…
hypetf
  • 36
  • 3
1
vote
0 answers

Azure Devops npm publish Angular library

I want to write a pipeline to publish an Angular library however, I'm getting an error npm ERR! code ENEEDAUTH npm ERR! need auth This command requires you to be logged in to https://registry.npmjs.org/ npm ERR! need auth You need to authorize this…
1
vote
0 answers

Vue.js / Vite - How to export components from one project and consume in another via NPM packages

I am trying to create a UI library which stores components and exports them to be used in multiple projects. Some components render without any issues, however, some components will not render and receive either of the following errors: [Vue warn]:…
Tom
  • 59
  • 7
1
vote
0 answers

How to publish CDK project to npm and deploy after install

I would like to publish a CDK typescript project to npm repository. The project contains an app and a stack. The what I would like to do is be able to install it by running npm install my-package and then just run npm run mycustomscriptname to…
CC.
  • 2,736
  • 11
  • 53
  • 70
1
vote
1 answer

Module Not Found - I have created a Basic React NPM package but getting an Error "Module Not Found"

I have created a basic react npm package using the command npx create-react-app following the geeksforgeeks-create-react-npm-package documentation but after publishing it, getting an error npm repo link: k-k-react-header-package import…
kashif750
  • 31
  • 6
1
vote
2 answers

Semantic Release publishing on package.json

I am currently try to auto publish my npm package to GitHub packages using semantic release with GitHub Actions. The package publishes successfully but when Installed, only the package.json file is found in the published package. I have a build…
1
vote
0 answers

How to create an npm package with a custom styled-components theme attached?

I've created a component library. I am using styled-components with an updated DefaultTheme in my styled.d.ts file. I am able to export my components into my other project, however they do not have any reference to their
kevin
  • 2,707
  • 4
  • 26
  • 58
1
vote
1 answer

Npm publish is failing with 400 Bad Request

I am trying to publish @babel/runtime package into my gitlab registry and while doing so i am facing E400 error. Adding the error logs below npm notice === Tarball Details === npm notice name: @babel/runtime npm notice version: …
Sai Vamsi
  • 111
  • 3
  • 19
1
vote
0 answers

Postinstall script not executing after publish

None of my scripts are working after publishing an npm package. I will try to give a simple example here to demonstrate the point. The package.json scripts object (relevant parts) looks like this: "scripts": { "install": "node…
unfocused
  • 13
  • 4