Building a Purple Experience
Components

Widget Component

6min
in the generic widget json, you configure the widget library for your project each library can contain one or multiple widgets if no generic widget json is present on your project, you can simply add one don't forget to register it in your urls json structure widget library the widget library contains the list of widgets from the same 3rd party provider (for example, the brochure provider 'weekli') field description name specifies the name of the widget library widgets specifies a list of widgets to be utilized in the experience resources specifies a list of global resources these resources are loaded whenever any widget from the same library is loaded in the view = required field widget element field description html specifies the name of the widget library resources specifies a list of resources that are loaded exclusively when their corresponding widget is loaded within the view = required field resource field description type it can either be a script or a style url the url of the resource content the content of the html element placement it can be placed either in the body or the head of the html page the placement won't make a difference if the position value is just before element / just after element position it can be positioned either at the top or the bottom of the placement (body/head), as well as before ( just before element ) or after ( just after element ) the widget's html properties all properties that we can find in the html element = required field the configuration is based on the widget config provided by the 3rd party provider definition of placements for widgets the widget component can be configured in any view in the views json the widget component can be configured in any view in the views json field description name specify library name widgetid specify the id for the widget from the library bidirectionalrouter bidirectional feature parameter for the widget when activated, this feature facilitates bidirectional routing communication between the experience and the widget = required field