Open AlexFrazer opened 8 years ago
Similar to Session.setDefault. Basically a set if not set behavior.
Session.setDefault
My common use case is for a List component, where it has a series of default options that I want to try to set, if they are not already set.
List
import {FlowRouter} from "meteor/kadira:flow-router"; import {BlazeComponent} from "meteor/peerlibrary:blaze-components"; import "./list.jade"; export const OPTIONS = { limit: 10, sort: {} } export class List extends BlazeComponent { onCreated() { super.onCreated(); FlowRouter.setDefaultQueryParams(OPTIONS); } // rest is not important }
Similar to
Session.setDefault
. Basically a set if not set behavior.My common use case is for a
List
component, where it has a series of default options that I want to try to set, if they are not already set.