0

I have a git repo for an Ember Addon:

https://github.com/lifegadget/ui-responsive-toolbelt

It passes all unit tests. It has been published to npm as ui-responsive-toolbelt. I have used npm's "link" functionality to test locally that this "addon" (in Ember parlance) works fine in consuming application when included in the package.json file as a dependency.

Surprisingly, and I'm completely flummoxed on this, when npm installs this dependency into an Ember project directory it brings across a vast majority of the files without complaining. From NPM's perspective it appears to be a clean install. Unfortunately an addon depends heavily on it's "entry point" which is the index.js in the root directory of the repo. I have very clearly included this file in the repo but for some reason it is not being brough over!

I have tried this on two computers and three Ember projects and all have the same outcome. Please help!


the error message I get from Ember-CLI when I try to start the server with ember serve is:

The package ui-responsive-toolbelt is not a properly formatted package, we have used a fallback lookup to resolve it at /path/to/project/node_modules/ui-responsive-toolbelt. This is generally caused by an addon not having a main entry point (or index.js).

This message is repeated twice and then I get:

The ui-responsive-toolbelt addon could not be found at /path/to/project/node_modules/ui-list/node_modules/ui-responsive-toolbelt.

4
  • I just confirmed your report. Maybe you need to npm publish again? Commented May 13, 2015 at 18:27
  • What npm version are you using? Commented May 13, 2015 at 18:27
  • npm is version 2.8.3 Commented May 13, 2015 at 18:49
  • @KevinBoucher yeah I have tried a few publishes to see if that would get things working but so far no luck Commented May 13, 2015 at 18:49

1 Answer 1

1
  1. I confirmed that your repo looks fine
  2. npm install ui-responsive-toolbelt does not download the index file

So the problem is that npm publish is not working properly. There is a bug filled for that. https://github.com/npm/npm/issues/5082

What you can do is publish again your addon using a recent npm version (or play with older versions) until you see that the index file is added too.

Sign up to request clarification or add additional context in comments.

1 Comment

Ok, thanks for pointing me to this issue. Looking through the long list of 'victims' I found enough of a thread that I was able to fix this with the following change: github.com/lifegadget/ui-responsive-toolbelt/commit/…

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.