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

Cannot publish npm package to GitHub packages

I'm trying to publish npm package to the GitHub package registry. Here is my package.json file and .npmrc file package.json { "name": "@chathurabuddi/constants", "version": "1.0.0", "description": "All constants", "main": "index.js", …
Chathura Buddhika
  • 2,067
  • 1
  • 21
  • 35
2
votes
1 answer

Issue with Publishing NPM Package (org.couchdb.user:USERNAME' is not in the npm registry)

Issue: I'm trying to publish my npm package https://www.npmjs.com/package/react-native-ultimate-modal-picker and it's coming up with the error. It's been 9 months since I last have made a publish and I just updated a ton of code and files. I also…
jefelewis
  • 1,850
  • 1
  • 27
  • 63
2
votes
0 answers

GitLab-CE 13.7.4: NPM publish 404 Not Found - PUT

I am trying to publish a private NPM package on a self-hosted GitLab. To do this, I created a GitLab project having ID = 9, to host all the NPM packages that I need. The package.json of the lib is: { "name": "@myscope/api-client", "version":…
1Z10
  • 2,801
  • 7
  • 33
  • 82
2
votes
1 answer

Verdaccio: how to publish to custom server from Github Actions with proper credentials?

I have a working verdaccio server hosted on a google cloud server. I am able manually publish to it, but am struggling to create a GitHub Action to publish to it when I push to master branch. I have a script that works perfectly when publishing to…
Adam B
  • 3,662
  • 2
  • 24
  • 33
2
votes
1 answer

Publishing Angular packges in offline Artifactory instance fails because of wombat-dressing-room URL

I work in an offline network with Artifactory, and I want to publish Angular packages to that Artifactory environment. For this, I use npm-offline-packager in my laptop, which has internet access to download all the Angular packages I need from…
Baruch Levin
  • 330
  • 3
  • 19
2
votes
1 answer

Sharing mongoose models via npm package

I'm writing a few applications that use the same DB and schemas. I need to share the mongoose model between all application- each application has her own express server. I tried to create a models server and requesting the JSONs useing mongoose-gen…
2
votes
3 answers

Published styled-components react library does not have access to user app ThemeProvider

So i'm building a design system for this company and the component system is displayed correctly in the design system storybook. But when I import it in the consumer app I get the following error TypeError: Cannot read property 'width' of undefined…
2
votes
0 answers

github actions publish fails - NPM ERR 404

npm ERR! 404 Not Found - PUT https://registry.npmjs.org/mypkg - Not found unable to publish via github actions, the build portion works fine i am able to publish this locally from my local machine terminal. without any issue. i attempted having…
earlyBirdDev
  • 383
  • 1
  • 2
  • 6
2
votes
1 answer

Publish a react component wrote with TypeScript to npm, but get undefined while import it

I tried to publish my own react component wrote with TypeScript to npm. I published it succussfully, but when I created a new react project and import the npm package which I built, some error occured: Error: Element type is invalid: expected a…
Kyle Mo
  • 21
  • 1
2
votes
0 answers

Bundled local dependencies in package throw errors on npm install

I am trying to publish a package that relies on an unpublished package, which needs to remain unpublished. I thought I had a solution: In development, the relative path is hardcoded in the package.json: { ... "dependencies": { …
Ned
  • 237
  • 3
  • 12
2
votes
2 answers

How to create a npm package with multiple vue directives? Or should I create one package per directive?

I am able to create an npm package by exporting a single vue directive in the src/index.js file. But how can I create a package that lets you use multiple vue directives. I am not able to export two vue directives in the same index.js file. export…
manb
  • 105
  • 10
2
votes
1 answer

Unable to publish npm package from Github?

I've published react-push-notify by using this command : npm login npm publish But when I want to publish again through Github ( private repository ) by following these steps: Add publishPackage to my package.json "publishConfig": {…
2
votes
1 answer

`npm publish` ignoring new additions to .npmignore

While building create-near-app, artifacts get created within the project tree. Some of these were added to a .npmignore file, but others were missed until I attempted to publish a new version and noticed that the npm package would be several hundred…
chadoh
  • 4,343
  • 6
  • 39
  • 64
2
votes
1 answer

How to run npm scripts at the global level, enforce on all node projects

I have a scenario where I have to run a validation script before npm publish happens and that I have to enforce it at the global level so that all node application run this validation script before it starts publishing. Like prepublishOnly applied…
2
votes
1 answer

npmjs.org - Unable to find a readme for

I'm a lead author of the npm package scramjet - since a month I have a problem regarding the visibility of the README.md in npmjs. The scramjet package in npm shows: "Unable to find a readme for scramjet@4.33.2" But at the same time the README.md…
Michał Karpacki
  • 2,588
  • 21
  • 34