🖼️
KASKO Frontend Documentation
  • README
  • Getting started
    • Setting up a new webapp
    • Webapp manifest
    • Building the flow
    • Defining layouts
    • Defining computed values
    • Defining dynamic paths
  • Core concepts
    • Forms
    • Validation
      • Using existing validators
      • Adding custom validators
    • Configuration
      • Price format
      • Date format
    • Performing API calls
    • Toggling visibility of components
    • Translations
    • Rules For Robust Application
  • Guides
    • Using logical statements (JsonLogic)
    • Adding discount codes
    • Developing Custom Plugins
    • Setting required requests
    • Adding save quote for later
    • Transforming request data
    • Manifest merging strategy
    • Knockout flow
    • Local pricing logic
    • Setting up dashboard policy profile
    • Handling offers
    • Repeater
  • Snippets
    • Reset input state
  • Useful resources
    • All component descriptions
    • JsonLogic core documentation
    • Kasko.js documentation
    • Example webapp
    • Example plugins (w/ various frameworks)
Powered by GitBook
On this page
  • Root level
  • Schema level
  1. Getting started

Webapp manifest

A webapp manifest is a JSON structure used to build webapps. The target audience for this is developers. In an ideal world developers should be able to build any application by constructing a webapp manifest.

Root level

{
  "version": "1.0",
  "schema": {
    // ...
  }
}
Variable
Required
Description

version

Yes

Signifies which parser to use for this manifest. If it's decided to change the structure of manifests, it will be required to bump this to 2.0. Then a different parser will be able to pick it up. For now, only 1.0 is used so this guide is focused only on this version.

schema

Yes

Contents of the manifest.

Schema level

{
  "config": {
    "initial_screen": "start",
    "currency_template": "(currency) (amount, 1.2-2, ',', ' ')",
    "date_format": "DD/MM/YYYY",
    "default_values": {
      "data.loss_enabled": true
    },
    "overwrite_values": {
      "data.theft_enabled": true
    },
    "computed_values": {
      "data.policy_start_date": {
        "value": {
          "type": "jsonlogic",
          "schema": {
            "var": "active_policy.quote.customer_input.start_date"
          }
        }
      }
    },
    "requests": [
      {
        "type": "quote"
      },
      {
        "type": "policy",
        "field_definition": [
          {
            "path": "data",
            "name": "optin1",
            "validation": "required_true"
          }
        ]
      },
      {
        "type": "payment"
      }
    ]
  },
  "layout": {
    // ...
  },
  "flow": [
    {
      // ...
    }
  ]
}
Variable
Required
Example
Description

config.initial_screen

Yes

"start"

Unique identifier (path) of the initial screen.

config.currency_template

No

"(currency) (amount, 1.2-2, ',', ' ')"

config.date_format

No

"DD/MM/YYYY"

config.default_values

No

{"field":"value"}

Object of default values applied to the form.

config.overwrite_values

No

{"field":"value"}

Overwrite input state values.

config.computed_values

No

{"field":{"value":{...}}}

config.requests

No

[{ ... }]

layout

No

{"custom":{"components":[ ... ]}}

flow

Yes

[{ ... }]

Last updated 9 months ago

See for more information.

See for more information.

Computes values and applies them into input state. See for more information.

An array of requests that should be performed for this webapp along with frontend specific field definition (validation rules). If, for example, there are some frontend only specific validation rules, they should be defined here. Other, both backend and frontend validation rules should be defined in the root field definition object (it's not stored in the manifest). More on this in the .

Definitions of the layouts that can be used in webapp flow. See for more information.

An array of component definitions. See for more information.

currency configuration article
date configuration article
computed values guide
api requests guide
layout guide
building the flow article