${ this.globel.getDate = function(){return new Date();}; } ${ var self = this; window.setInterval(function(){ (self.SelfHTMLElement).innerHTML = this.globel.getDate(); },1000); }
更新时间:2019-12-31 15:16:42
html模板语法,简单的实现,利用了正则表达式匹配,然后用function将其封装为函数,并更改指针调用