SOURCE

console 命令行工具 X clear

                    
>
console

async function test () {
  return 'test'
}

async function test1 () {
  console.log(a, '123')
  var val = await Promise.reject('1')
  console.log(val, 'val-1')
  return 1
}

test1().catch((err) => {
  console.log(err, 'err')
})
<div class="box">
  <span class="item">垂直居中</span>
</div>
.box {
  width: 200px;
  height: 200px;
  position: relative;
  border: 1px solid red;
}
.item {
  position: absolute;
  border: 1px solid green;
  width: 100px;
  height: 50px;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: auto auto;
}