SiteGenesis / Server-side JS / Source: app_storefront_controllers/cartridge/controllers/Default.js

'use strict';

 * Controller that determines the page rendered when a customer accesses the site domain (
 * The Start function that it exports points at the controller that renders the home page.
 * @module controllers/Default

/* Script Modules */
var app = require('~/cartridge/scripts/app');
var guard = require('~/cartridge/scripts/guard');

 * This function is called when the site is turned offline (not live).
function offline() {

 * Module exports

 * Web exposed methods
/** Sets the page rendered when the site domain is accessed.
 * @see module:controllers/Home~show */
exports.Start = app.getController('Home').Show;
/** Sets the controller called when the site is offline.
 * @see module:controllers/Default~offline */
exports.Offline = guard.ensure(['get'], offline);

X Privacy Update: We use cookies to make interactions with our websites and services easy and meaningful, to better understand how they are used. By continuing to use this site you are giving us your consent to do this. Privacy Policy.