dist/functions.js
/**
 * Displays the current time once a second.
 * @customfunction
 * @param invocation Custom function handler
 */
Displays the current time once a second.
@customfunction
@param invocation Custom function handler
Displays the current time once a second . @customfunction @param invocation Custom function handler
function clock(invocation) {
  var timer = setInterval(function () {
    var time = currentTime();
    invocation.setResult(time);
  }, 1000);
  invocation.onCanceled = function () {
    clearInterval(timer);
  };
}
function clock ( invocation ) { var timer = setInterval ( function ( ) { var time = currentTime ( ) ; invocation . setResult ( time ) ; } , 1000 ) ; invocation . onCanceled = function ( ) { clearInterval ( timer ) ; } ; }
Displays the current time once a second.
Displays the current time once a second .