Skip to content

Unify Vue coding style #31

@NingW101

Description

@NingW101

As we are composition API with Single-File Components(SFC), <script setup> is strongly recommended for a more succinct and ergonomic syntax.

In the code base, most of vue components use SFC + <script setup> but there are still a few components that don't follow it. Although this does not affect functionality, it's better to modify them to achieve a unified coding style.

For example,

// <Footer.vue>
<script lang="ts">
import { defineComponent, reactive, toRefs, onMounted, watch } from "vue";
import { useRouter } from "vue-router";
import { NavItem } from "../common/types";

export default defineComponent({
  name: "FooterComp",

  setup() {}
});

Some references:

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions