Search code examples
intellij-ideameteoriron-router

Meteor iron:router as library in Intellij 14


I'm attempting to mark all packages in my Meteor project as JavaScript libraries so I can have features such as auto-completion, etc. in Intellij 14.

Following the instructions found here:

  1. I opened up the package.json file under /.meteor,
  2. clicked on the "import packages as libraries" option (yes, iron:router is listed)

However, the Router object remains unresolved, even though it worked for the other libraries. I noticed someone mentioned later:

Code completion for other Underscore.js functions such as bind, partial, etc and packages like Iron:Router and others are not as complete

Edit: Pressing alt-enter with the Router object selected, as Matt K suggested, only gives the options of creating a variable named "Router" or renaming the reference, not actually resolving the iron:router library as a dependency.

Does anyone have any suggestions on resolving the iron router library?


Solution

  • Turns out this was as easy as I thought it was with going to .meteor/packages.json and clicking on "import packages as libraries". Not sure what the issue was before but following that same 2-step process whenever the listing changes solves any library recognition issues.