export var syncDriver = function (interval) {
    if (interval === void 0) { interval = 10; }
    return function (update) {
        var isRunning = true;
        return {
            start: function () {
                setTimeout(function () {
                    update(0);
                    while (isRunning)
                        update(interval);
                }, 0);
            },
            stop: function () { return (isRunning = false); },
        };
    };
};
//# sourceMappingURL=utils.js.map