is there any way to install smart.json dependencies using meteor cli? - meteor

Since Meteor 0.9.0 it's posible to install dependencies from atmospherejs just using the meteor cli without install meteorite package manager.
However, is it posible to install all the dependencies declared in smart.json file without install meteorite (i.e. just using meteor cli)?
Thanks in advance.

smart.json is no longer used since Meteor 0.9. The dependencies of an app are stored in .meteor/packages, and are automatically installed when you run meteor run, and when the app restarts automatically after its files are changed. That is, the meteor tool will update the package catalog and install updated packages automatically.

Related

Downgrade Firebase 9.6 to 9.2.0

What commands must I follow on the command line to downgrade. I ran uninstall and reinstalled as well as nom i -S firebase#... but now when I reload the app it just crashes.
If you have to install an older version of a package, just specify it
npm install <package>#<version>
For example: npm install firebase#9.2.0
You can also add the --save flag to that command to add it to your package.json dependencies, or --save --save-exact flags if you want that exact version specified in your package.json dependencies.
The install command is documented here: https://docs.npmjs.com/cli/install
If you're not sure what versions of a package are available, you can use:
npm view firebase versions
And npm view can be used for viewing other things about a package too.
https://docs.npmjs.com/cli/view
don't forget to remove .lock file first to rebuilt the depedency
can u give the error messege for us....

meteor requires npm install on each new machine

I just cloned my meteor github repo to a new machine and now I have to npm install some packages again. I thought that they are part of the meteor app once I have them installed. (and I checked. they are in the node_modules folder and listed in the packages.json). Nonetheless, I get the error:
Can't find npm module 'react'. Did you forget to call 'Npm.depends' in package.js witin the 'modules-runtime'package?
I am running meteor 1.3.1

meteor won't start becaus it is missing npm

I just checked out my meteor project from github and tried to run it, but now meteor doesn't want to start, telling me that npm is missing
I start my project as follows:
$> MONGO_URL='mongodb://localhost:27017/meteor' mrt
...
=> Started proxy.
=> Errors prevented startup:
While building the application:
error: no such package: 'npm'
=> Your application has errors. Waiting for file change.
In my project I use npm like
var fs = Npm.require('fs');
What I don't understand is why it doesn't work. I tried to install npm
$> mrt add npm
but that didn't fixed it. Any suggestions what the problem might be ?
When you run the app with meteor command it only uses the packages installed locally in the /packages folder and built-in Meteor packages. To also install the atmosphere packages, you should run the app with mrt command. Alternatively, you could run mrt install, which downloads the atmosphere packages to the /packages directory, and thus allows you to start the app with meteor.

How to add router package to Meteor js?

How to add Router Package to Meteor Js.I didn't have any idea about this so please help me.I am new to Meteor so is there any best reference for Meteor learn quickly.
With the new version of Meteor this is now:
$ meteor add iron:router
The meteor-router project has shifted to iron-router
You can use meteorite to install it. To meteorite:
npm install -g meteorite
And then you can add iron-router by:
mrt add iron-router
I would strongly recommend iron-router, which can be added with just meteor add iron-router from within your project root directory. However, if you install meteorite, it will give access to all the packages listed on Atmosphere, which include some other routing solutions.
Metor JS does not come with support for routing (i.e. having separate pages) out-of-the-box. But it is easy to add that using the router smart package.
$ mrt add router
But before adding router, you must need to install meteorite, You can install meteorite by using this command.
$ npm install -g meteorite
If your system requires root access to install global npm packages, make sure you use the -H flag:
$ sudo -H npm install -g meteorite
Install meteorite first. before installing the 'router' package you should install couple of other packages too. "HTML5-History-API" and "page-js-ie-support" packages. These are for the router to work in older versions of IE that doesn't support push state API.
mrt add HTML5-History-API
mrt add page-js-ie-support
mrt add router
Iron-router appears to be neither well-engineered (i.e. you can't prevent route changing without Monkey-patch) nor well-maintained at this moment. I recommend considering https://github.com/meteorhacks/flow-router/ as an alternative.

Can't install Iron-Router

i get this when i type mrt add iron-router in my meteor app
this is on a mac
smart.json changed.. installing from smart.json
smart.json changed.. installing from smart.json
✓ iron-router
tag: https://github.com/EventedMind/iron-router.git#v0.5.4
/usr/local/lib/node_modules/meteorite/lib/sources/git.js:108
throw "There was a problem cloning repo: " + self.url;
^
There was a problem cloning repo: https://github.com/EventedMind/iron-router.git
what can i do to install iron-router ?
try
mrt uninstall --system
Then reinstall iron-router again.
If it still happen maybe the author forget to push tag. ( if newer version released)
If u want to use it right now. Clone it into your packages folder
Try:
meteor add iron-router
This is the newer way to install Meteor packages.
Note: Also make sure you run this command in the root directory of your Meteor project.

Resources