props state 类型定义input 事件 event 类型定义// 定义 Props 类型
export interface Props {
name: string;
value: string;
}
// 定义 State 类型
export interface State{
value: string;
}
// 使
.editorconfig 编辑器配置缩进等
root = true
end_of_line = lf
insert_final_newline = true
charset = utf-8
indent_style = space
indent_size = 4
.babelrc babel编辑配置
{
"presets": ["env", {
npm install -g typescript
index.ts 后缀名.ts 编译成 .js> tsc index.ts
index.ts ===> index.js
string 字符串
number 数字
boolean 布尔值
date 日期
ob
// 启动
> service mysqld start
// 关闭
> service mysqld stop
// 重启
> service mysqld restart
> yum install -y perl perl-Module-Build net-tools autoconf libaio numac
在ios软键盘收起时,页面键盘位置的内容留白
解决方法:
// input 添加 blur 事件
// ios键盘弹起 失焦后页面复原
window.scrollTo(0,0)
// vue
<input @blur="Inputblur" />
Inputblur(){
window.scrollTo(0,0)
}
docker images 镜像列表
docker ps 服务列表
docker 隐藏打包文件
.dockerignore
.git
node_modules
npm-debug.log
Dockerfile
FROM node:10.16.0-alpine
WORKDIR /app
RUN npm install -
环境: 阿里云 centos 7服务器
> ssh root@192.168.1.1
> 输入密码登陆查看ssh状态 默认是开启的
//查看状态
> systemctl status sshd
// 参考
// 导入
import hljs from 'highlight.js/lib/highlight';
import 'highlight.js/styles/default.css';
import javascript from 'highlight.js/lib/languages
安装 hiper 执行命令
// 安装
sudo npm install hiper -g
//报错
Failed to download Chromium r686378! Set "PUPPETEER_SKIP_CHROMIUM_DOWNLOAD" env variable to skip download.
Puppeteer 安装失败
解决方法
安装
> curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.31.1/install.sh | bash安装完成后重启下终端命令行工具
# 查看信息
> nvm -v
# 查看node版本列表
> nvm ls-