Page Bindings

Page bindings are configuration based interactions between widgets. This allows simple re-usable JSON definitions for driving UI flows. There are several page bindings available for each widget. For a Page Binding, there is a typically a widget that triggers a transition, and the other widget that receives it and modifies the state of that widget.

For Example, in a TODO list application, lets assume there is a FORM to enter TODO and a TABLE view to refresh. We need to bind the FORM submit to a logic that updates a TODO state, and that is reflected in the grid immediately. In this case, we setup 2 page bindings,

  1. The defaultFormSubmit this will trigger a FORM SUBMIT, which triggers the logic to store the TODO item in a state.
  2. The refreshGridAfterFormSubmit this will refresh the grid after FORM SUBMIT event is successful.

    "pageBinding": {
    	"todo-form": {
    		"todo-form-submit-binding": {
    			"name": "defaultFormSubmit",
    			"provider": "FormWidget",
    			"providerId": "",
    			"providerTypeId": "",
    			"providerSchemaId": "",
    			"metadata": {
    					"type": "widget",
    					"featureId": "todo-form-submit-binding"
    			},
    			"onSubmitTransitions": [
    					{
    						"type": "FORM_REFRESH",
    						"source": "self"
    					}
    			]
    		}
    	},
    	"todo-list": {
    		"todo-grid-refresh": {
    			"name": "refreshGridAfterFormSubmit",
    			"provider": "FormWidget",
    			"providerId": "todo-form",
    			"providerTypeId": "",
    			"providerSchemaId": "",
    			"metadata": {
    				"type": "widget"
    			}
    		}
    	}
    }