zoukankan      html  css  js  c++  java
  • angularcli填坑系列(持续更新...)

    1.在xx.ts中引入css样式无效

    @Component({
      selector: 'app-root',
      templateUrl: './app.component.html',
      styleUrls: ['./app.component.css']
    })
    解决:去除 styleUrls中的  ./
                styleUrls: ['app.component.css']
     
    2. 在引入bootstrap4 时 缺少 popper,js

          解决:.angular-cli.json 文件中scripts节点 ,引入的bootstrap.min.js 更换为 
    ../node_modules/bootstrap/dist/js/bootstrap.bundle.js
     
     
     
     
     
     
    3.局部路由跳转到其他页面,其页面宽度高度是根据内容。要使其根据整体100%
     

       解决:在 其组件中的css 文件中添加样式

    使用:host伪类选择器,用来选择组件宿主元素中的元素(相对于组件模板内部的元素)

    :host {
    100%;
    height: 100%;
    padding: 0px;
    margin: 0px;
    }
     
    4.引入ngx-echarts,在全部配置完成后,报错!!!
    百度N久没法解决, 在GitHub上翻了下Issues,发现

    发现可能是包冲突,删除node_modules文件夹,重新npm 后正常

  • 相关阅读:
    8.指针小结
    8.指针
    7.数组
    6.结构化程序设计
    python之迭代器
    1.python基础—有这篇文章足够
    python装饰器,细致讲解
    django客户管理系统-使用modelform对HTML标签统一添加样式
    python之md5使用方法
    git干货教程
  • 原文地址:https://www.cnblogs.com/zhuzy/p/8031771.html
Copyright © 2011-2022 走看看