问题如下解决办法StackOverflow Error TS2339: Property 'Connection' does not exist on type 'Navigator'图示export type Navigator = NavigatorNetworkInformation export declare interface NavigatorNetworkInformation { readonly connection?: NetworkInformation } type Megabit = number type Millisecond = number export type EffectiveConnectionType = '2g' | '3g' | '4g' | 'slow-2g' | 'unknown' export type ConnectionType = | 'bluetooth' | 'cellular' | 'ethernet' | 'mixed' | 'none' | 'other' | 'unknown'
原由在 windows 编写的 shell 文件 复制到 centos 下无法运行其主要原因是文件编码不对解决使用vi工具 vi test.sh利用如下命令查看文件格式 :set ff 或 :set fileformat 可以看到如下信息 fileformat=dos 或 fileformat=unix 利用如下命令修改文件格式 :set ff=unix 或 :set fileformat=unix :wq (存盘退出)其他使用 dostounix 一劳永逸
前言在 vue 项目中使用了 static 静态资源文件,开发环境下直接访问没什么问题,在编译之后是不存在 static 这个目录下的文件的,所以需要 copy-webpack-plugin 这个插件来实现 static 目录的复制使用方法npm 包地址 CopyWebpackPlugin 安装 npm install copy-webpack-plugin -D or yarn add copy-webpack-plugin -D使用如下// 在 vue.config.js 里 const CopyPlugin = require("copy-webpack-plugin"); module.exports = { plugins: [ new CopyPlugin({ patterns: [ { from: "source", to: "dest" }, { from: "other", to: "public" }, ], }),
预览效果实现代码<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>Echarts实现心电图效果</title> <script src="https://cdn.bootcss.com/echarts/3.7.1/echarts.js"></script> </head> <body> <div id="totalFlowRate" style="height:300px;"></div> </body> <script type="text/javascript"> var totalFlowRate = echarts.init(document.getElementById('total
说明在日期时间选择组件里,又需求在当日之后才可选在的需求,这里简单记录下代码computed: { callTimeOptions() { return { disabledDate: e => e.getTime() < Date.now() - 8.64e7, selectableRange: moment().format('HH:mm:ss') + ' - 23:59:59' }; } }
lettered
生,亦我所欲也;义,亦我所欲也。