zoukankan      html  css  js  c++  java
  • 移动端自适应

    //设置页面字体
    window.addEventListener('DOMContentLoaded', () => {
    const html = document.querySelector('html');
    let size = window.innerWidth / 10;
    size = size > 75 ? 75 : size;
    html.style.fontSize = size + 'px';
    })
    //配置不同环境下是否启用debugger工具
    // if(window.location.hostname != 'agent.ewszjk.m.jaeapp.com' || window.location.hostname != 'm.net'){
    if (process.env.NODE_ENV !== 'production' || true) {
    let el = document.createElement('div');
    document.body.appendChild(el);
    eruda.init({
    container: el,
    // tool: ['console', 'elements', 'network'],
    useShadowDom: true
    });
    }

  • 相关阅读:
    java
    MVC4重复提交数据
    cache
    Nosql
    MVC4重复提交
    PHP Java
    .net performance
    How the Runtime Locates Assemblies
    android
    window.onscroll
  • 原文地址:https://www.cnblogs.com/liea/p/11999809.html
Copyright © 2011-2022 走看看