Request Namespace
Linz adds to the Express req object, an object which you can use to access Linz information about the incoming request.
The Linz namespace exists at:
And is a copy of the object you receive when requiring Linz, for example require('linz').
It has the keys:
notificationswhich is an array of notifications Linz will display.cachewhich is an internal cache that Linz uses.
Depending on which view is currently being requested, you'll also get extra information.
The Linz namespace can be used whenever Linz passes you req and becomes a very handy API to get more information about the request currently being served.
Model form#
The model form, both create and edit views, also recieve:
modelwhich is a reference to the current model, the basic Mongoose version of the model.model.linzwhich is a reference to the current model, which extra Linz-specific information included.model.linz.formwhich is a reference to the model form DSL.
Model list#
The model list view also receives:
modelwhich is a reference to the current model, the basic Mongoose version of the model.model.linzwhich is a reference to the current model, which extra Linz-specific information included.model.linz.listwhich is a reference to the model List DSL.
Model overview#
The model overview view also receives:
modelwhich is a reference to the current model, the basic Mongoose version of the model.model.linzwhich is a reference to the current model, which extra Linz-specific information included.model.linz.overviewwhich is a reference to the model overview DSL.