script marko-init
    ---
    var markoWidgets = require('marko-widgets');
    var componentsTemplate = require('./components.marko');

    function componentsDataProvider(callback) {
        componentsTemplate.renderToString({}, function(err, html, out) {
            var widgetIds = markoWidgets.getRenderedWidgets(out);

            // Serialize the HTML and the widget IDs to the browser
            callback(null, {
                    html: html,
                    widgetIds: widgetIds
                });
        });
    }
    ---

<!DOCTYPE html>
html lang="en"
    head
        meta charset="UTF-8"
        title -- Marko Widgets Tests
    body
        await(components from componentsDataProvider)
            script
                ---
                window.components = ${JSON.stringify(components)};
                ---

        div id="test"
        div id="mocha"
        div id="testsTarget"
