Tutorial by Examples: e

If you're running a replica set or have a need to shard your database, you'll want an upstart script that looks something like this: # /etc/init/myapp.conf description "myapp.mydomain.com" author "[email protected]" # used to be: start on startup # until we found som...
https://www.phusionpassenger.com/ https://github.com/phusion/passenger https://github.com/phusion/passenger/wiki/Phusion-Passenger:-Meteor-tutorial#wiki-installing
Both Chrome and Safari have built in debuggers. With Chrome, all you have to do is right-click on a web page and 'Inspect Element'. With Safari, you'll have to go into Preferences > Advanced and click on 'Show Develop menu in menu bar'. With Firefox, you'll need to install Firebug
You'll need to add debugger statements to your code: Meteor.methods({ doSomethingUself: function(){ debugger; niftyFunction(); } });
For server side debugging, you'll need to use a tool like Node Inspector. Before you get started, check out some of these useful tutorials. HowToNode - Debugging with Node Inspector Strongloop - Debugging Applications Easily Debugging Meteor.js Walkthrough with Screenshots of Using Node Inspecto...
Besides Node Inspector, some people have reported success with a npm utility called debug. MeteorHacks - Debugging Meteor with npm debug
As of Meteor 1.0.2, there's a new command shell which you can use to do interactive debugging and manage your app from the server side, just like you do with the Chrome Console on the client side! Check it out: meteor shell
Meteor Dump Meteor Toys Constellation Meteor DevTools
Template helpers are an essential part of Blaze and provide both business logic and reactivity to a Template. It is important to remember that Template helpers are actually reactive computations that are rerun whenever their dependencies change. Depending on your needs, Template helpers can be def...
Static server assets must be placed in the private directory. Text files Text files can be accessed by using the Assets.getText(assetPath, [asyncCallback]) method. For example, the following JSON file is named my_text_asset.json and is located in the private directory: { "title": &...
// thecontroller.js $scope.sendVerifyEmail = function() { console.log('Email sent, whaaaaam!'); currentAuth.sendEmailVerification(); } // where currentAuth came from something like this: // routerconfig .... templateUrl: 'bla.html', resolve: { currentAuth:['Auth', functio...
layout_text_to_speech.xml <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:pad...
Ensure that you install the correct npm dependencies (babel decided to split itself into a bunch of packages, something to do with "peer dependencies"): npm install webpack webpack-node-externals babel-core babel-loader babel-preset-react babel-preset-latest --save webpack.config.js: mo...
This is very common, you memorize a path to a file or folder, you open up Vim and try to write what you've just memorized, but you are not 100% sure it's correct, so you close the editor and start over. When you want the path completion feature, and you have a file /home/ubuntu/my_folder/my_file a...
To delete some lines of text when you don't know exact number of lines to delete, you try 10dd , 5dd , 3dd until you remove all the lines. Relative line numbers solves this problem, suppose we have a file containing : sometimes, you see a block of text. You want to remove it but you cannot d...
The following command executes :command on lines 23 to 56: :23,56command NB: Ranges are inclusive by default.
In the following command the range starts 6 lines above the current line and ends 3 lines below: :-6,+3command
. represents the current line but it can also be omitted entirely. $ represents the last line. % represents the whole buffer, it is a shortcut for 1,$. The two commands below execute :command on every file from the current line to the last line: :.,$command :,$command The command below e...
The commands below execute :command on every line from the first matching from to the first matching to: :/from/,/to/command " from next 'from' to next 'to' :?from?,/to/command " from previous 'from' to next 'to' :?from?,?to?command " from previous 'from' to previous 'to' ...
Line offsets can be used to adjust the start and end lines: :/foo/-,/bar/+4command " from the line above next 'foo' to 4 lines below next 'bar' See :help search-offset.

Page 395 of 1191