Skip to content
Jesse de Vries edited this page Jun 29, 2015 · 1 revision

Intent : object

View repository or documentation

Kind: global namespace
Summary: Intent lets your Meteor application remind a user's initial action or page over several route changes. Designed for use with iron:router.
Author: Jesse de Vries jessedvrs@gmail.com
License: MIT (c) 2015 Lifely

Intent.configure(conf)

Configure Intent

Kind: static method of Intent

Param Type Description
conf Object Configuration object
conf.debug Boolean Enable debugging mode (logs some info to the console)
conf.default_route_name String Set default route name
conf.default_route_params Object Set default route params
conf.default_route_options Object Set default route options

Intent.go(route_args, [callback], [intent_options])

Go to another route with iron:router, intentionally

Kind: static method of Intent

Param Type Description
route_args Object
route_args.route String The name of the route
[route_args.params] String The parameters for the route
[route_args.options] String The options for the route
[callback] Callback The callback for the intent
[intent_options] Object The options for the intent
[intent_options.prevent_going_back] Object Prevent the intent to go back

Intent.return(route_name, [return_options])

Return from an intent.

Kind: static method of Intent

Param Type Description
route_name String The name of the route whence the intent was initialized
[return_options] Object Options for the return
[return_options.arguments] Array Arguments you want to pass to the callback
[return_options.fallback_action] Callback Fallback action for the intent
[return_options.fallback_route] Object Fallback route for the intent
[return_options.fallback_route.name] String Fallback route for the intent (name)
[return_options.fallback_route.params] Object Fallback route for the intent (params)
[return_options.fallback_route.options] Object Fallback route for the intent (options)

Intent.exists(route_name) ⇒ Boolean

Check whether an intent currently exists, by route name

Kind: static method of Intent
Returns: Boolean - exists Whether the intent exists

Param Type Description
route_name String The name of the route to test