【问题标题】:console.log to be executed from a html file ANGULAR要从 html 文件 ANGULAR 执行的 console.log
【发布时间】:2017-07-13 15:54:11
【问题描述】:

有点疯狂……

有没有办法让 console.log() 从 html 文件中运行,如下所示:

<option (click)="consol.log('printed')">Test</option>

没有具体要求,只是想知道

【问题讨论】:

    标签: javascript html angular


    【解决方案1】:

    是的

    <button onclick="console.log('printed')">print</button> 
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2018-06-14
      • 1970-01-01
      • 1970-01-01
      • 2018-08-23
      • 1970-01-01
      • 2014-12-22
      • 1970-01-01
      • 2021-07-24
      相关资源
      最近更新 更多