Accounts.sendResetPasswordEmail

Server Accounts.sendResetPasswordEmail(userId, [email]) import { Accounts } from 'meteor/accounts-base' Source Send an email with a link the user can use to reset their password. Arguments userId String The id of the user to send email to. email String Optional. Which address of the user's to send the email to. This address must be in the user's emails list. Defaults to the first email in the list.

Meteor.userId

Anywhere but publish functions Meteor.userId() import { Meteor } from 'meteor/meteor' Source Get the current user id, or null if no user is logged in. A reactive data source.

Renderable content

Renderable Content A value is renderable content if it is one of the following: A template object like Template.myTemplate An unrendered View object, like the return value of Blaze.With null or undefined Internally, renderable content includes objects representing HTML tags as well, but these objects are not yet part of the officially-supported, public API.

this.changed

Server this.changed(collection, id, fields) Source Call inside the publish function. Informs the subscriber that a document in the record set has been modified. Arguments collection String The name of the collection that contains the changed document. id String The changed document's ID. fields Object The fields in the document that have changed, together with their new values. If a field is not present in fields it was left unchanged; if it is present in fields and has a val

Accounts.onEmailVerificationLink

Client Accounts.onEmailVerificationLink import { Accounts } from 'meteor/accounts-base' Source Register a function to call when an email verification link is clicked in an email sent by Accounts.sendVerificationEmail. This function should be called in top-level code, not inside Meteor.startup(). Arguments callback Function The function to call. It is given two arguments: token: An email verification token that can be passed to Accounts.verifyEmail. done: A function to call when the

Meteor.loginWithPassword

Client Meteor.loginWithPassword(user, password, [callback]) import { Meteor } from 'meteor/meteor' Source Log the user in with a password. Arguments user Object or String Either a string interpreted as a username or an email; or an object with a single key: email, username or id. Username or email match in a case insensitive manner. password String The user's password. callback Function Optional callback. Called with no arguments on success, or with a single Error argument on

Change log

2016/04/16: Switch order of Code Style and Application structure sections. PR #383 2016/04/16: Added Writing Packages - Creating an npm package and Using Packages - Overriding packages - npm. PR #381 2016/04/07: Add more examples and details on application structure using imports. PR #356 2016/04/04: Add more content on writing and publishing Atmosphere packages. PR #339 2016/04/03: Add back in build tool default loading order rules. PR #340 2016/04/01: Added CoffeeScript exports syntax. P

Accounts.findUserByUsername

Server Accounts.findUserByUsername(username) import { Accounts } from 'meteor/accounts-base' Source Finds the user with the specified username. First tries to match username case sensitively; if that fails, it tries case insensitively; but if more than one user matches the case insensitive search, it returns null. Arguments username String The username to look for

Meteor.apply

Anywhere Meteor.apply(name, args, [options], (Boolean), [asyncCallback]) import { Meteor } from 'meteor/meteor' Source Invoke a method passing an array of arguments. Arguments name String Name of method to invoke args Array of EJSON-able Objects Method arguments (Boolean) , or undefined options.noRetry (Client only) if true, don't send this method again on reload, simply call the callback an error with the error code 'invocation-failed'. asyncCallback Function Optional ca

Contribution guidelines

Please submit clarifications and improvements to the Guide! If it’s just a small fix, go ahead and open a PR. If it’s something more major, please file an issue for discussion first. Using the change log If you are adding significant new content, please take a moment to include an update to the changelog in your PR. Writing tips Things to be aware of: Always use specific IDs on headers so that we can change them later: // bad ## Using schemas with collections // good <h2 id="schemas-with-co