This class handles layout templates and
the creation thereof. Typically, a layout instance is
created with a set of Template parts that
are assembled from an indexed list of templates.
Each template part can be passed either as a predefined
template or as an arrow function that returns a string
typed template. Those are called template generators.
Please make sure to always use Vue's syntax when you
use this feature because this class does not handle
validation of the underlying templates.
The currently supported layout as of this version of
the software are the following:
{@link Component}: Uses a single component page, e.g. a log-in widget.
{@link Flex}: Uses flexible components, i.e. position of card depends on size of previous cards.
{@link Grid}: Uses a components grid, i.e. uses a 12-columns grid of cards.
example
Using the Layout class
// create a new layout constlayout = newLayout([{ body:"<template>...</template>" }]);
// or using a generator constlayout = newLayout([{ generator: () => { // doing some magic tricks here // and here also
// then return as string return"<template></template>"; }}])
The template parts that are assembled to build
the layout. Template parts are concatenated in
a sequential process where the indexes define
the order of assembly.
This class handles layout templates and the creation thereof. Typically, a layout instance is created with a set of Template parts that are assembled from an indexed list of templates.
Each template part can be passed either as a predefined template or as an arrow function that returns a
string
typed template. Those are called template generators. Please make sure to always use Vue's syntax when you use this feature because this class does not handle validation of the underlying templates.The currently supported layout as of this version of the software are the following:
Using the Layout class
Properties
The template parts that are assembled to build the layout.
v0.1.0