Arlo home

Bundle Template

The Bundle Template control displays one package from the Arlo Storefront Packages API. Its bundled template includes the package details, included course items, and an Upcoming Events sub-control for each course.

Getting Started

Follow the general getting started guide, add a target element, and configure the control.

                document.addEventListener("arlojscontrolsloaded", function () {
                    const bundleTemplateControl = {
                        moduleType: "BundleTemplate",
                        targetElement: "#bundle-detail",
                        regionCode: "default",
                        maxCount: 3,
                        overwritePageTitle: true,
                        customUrls: {
                            eventtemplate: "/course"
                        }
                    };


                    new ArloWebControls().start({
                        platformID: "your-platform.arlo.co",
                        modules: [bundleTemplateControl]
                    });
                });
            

The control resolves the package from ?package=<id> or ?package=<id>-<slug> in the page URL. Set packageID when a fixed package should be shown or when the URL does not provide a package.

Configuration

FieldTypeDefaultDescription
packageIDnumberThe package to display when no package ID is present in the configured URL parameter.
regionCodestringdefaultThe Storefront region used to retrieve the package.
queryStringConfigarraypackageThe URL parameter names to check for a package ID.
maxCountnumber3The maximum number of upcoming dates shown for each included course.
eventsTemplatestringThe template selector for the per-course Upcoming Events sub-controls.
overwritePageTitlebooleanfalseReplaces the browser page title with the package name.
customUrls.eventtemplatestringThe URL used by the included Upcoming Events controls for event-template links.
noResultsTextstringThe message displayed when the package has no course items.
messagestringThe loading placeholder message.

Template Data

The bundled template provides package fields including name, code, availability, Summary, Description, AdvertisedDuration, HeroImageUri, ListImageUri, BestOffer, ComparativeOffer, and Items. Each item includes its package-item data and template data. Custom templates can use formatOffer(offer, preferInclusive) and renderDescription(markdown).