<template>
  <view class="p-30">
    <view class="my-25 text-28 font-bold">{{ info.title }}</view>
    <view class="py-15 text-gray text-25 border-bottom">{{ info.createTime }}</view>
    <view class="pt-10">
      <u-parse :content="info.content"/>
    </view>
  </view>
</template>

<script>
import {articleInfoReq} from "@/api/common";

export default {
  name: "article",
  data() {
    return {
      info: null
    }
  },
  methods: {
    async getInfo(id) {
      const {data} = await articleInfoReq(id)
      this.info = data
    }
  },
  onLoad({id}) {
    this.getInfo(id)
  }
}
</script>