当前位置:网站首页>Debug on TV screen

Debug on TV screen

2022-04-23 14:16:00 Ruirui junior

One : introduce debug.v3.js file

Two :debugLog(), amount to console.log()

debug.v3.js

(function() {
  var opt = {
    enable: true, 
    isMsgAppend: true, //false Every one of them log Insert information into panel Bottom
     
  };
  window.debugLog = debugLog;
  if (!opt.enable) {
    return false;
  }

  var debugHtml = '<div id="log-panel"  class="scrollable" style="text-align: left;display:block;position: fixed;  top: 0; left: 0; width: 800px;height:100%;overflow:auto; z-index: 99999; color: #13F713; background: rgba(0,0,0,0.7);  padding:5px 0; text-decoration: none;"></div>';

  document.body.innerHTML += debugHtml;
  var panel = document.querySelector('#log-panel');
  var logPanel = document.getElementById('log-panel');

  function obj2str(value) { // Object to string
    var valueType = "&

版权声明
本文为[Ruirui junior]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204231408339188.html