vue3.0中使用nextTick

vue3.0 1、引入 import { nextTick } from 'vue' 2、具体使用,配合异步 setup() { const message = ref('Hello!') const changeMessage = async newMessage => { message.value = ne...

golang 前补0

func StrPad( str int64, index int) string { ending := strconv.FormatInt(str, 10) switch { case len(ending) index: return fmt.Sprintf("%."+fmt.Sprintf("%vs", index), ending[len(ending)-...

Golang如何获取当前年份月份日

众所周知Golang的时间格式化很奇葩 date := time.Now().Format("2006-01-02 15:04:05") 只有写以上参数才可获得对应的时间格式,所以我们也可以利用这个方法获取当前时间的年月日时分秒 year:=time....

关闭linux某个端口号

说不清楚是第几次查这个命令了,记不住 查看占用端口的进程号 netstat ano|grep 端口号 netstat 用来查看端口监听情况的 grep 查看 杀死某个进程号 kill -9 PID