createPage

Function

Given a Page model, create the item, protect it, share it, connect it to the site and upload any resources.

Parameters

Parameter Type Default Notes
model Required IModelTemplate

Page model to be created as an Item

options Required {
assets:
IItemResource[]
shareTo:
any[]
}

object containing shareTo, and space for future additions

hubRequestOptions Required IHubRequestOptions

IRequestOptions object, with isPortal

Returns

Promise<IModel>
Property Type Notes
item IItem
data Optional [key: string]: any
resources Optional [key: string]: any

Function defined in sites/src/pages/create-page.ts:26