Vue3 page basic code snippet

I am using VSCode, set the fragment path as

Management => User Code Snippet => New Global Snippet File

{
	"vue3": {
    "prefix": "vue3",
    "body": [
      "<template>",
      "  <div class=\"$1\">",
      "$2",
      "  </div>",
      "</template>\n",
      "<script setup lang=\"ts\">",
        "import { ref } from \"vue\" ",
      "$3",
      "</script>\n",
      "<style lang=\"less\" scoped>",
      "$4",
      "</style>"
    ],
    "description": "vue3 template"
  }

}

In this way, when creating a new page, you only need to enter vue3 to quickly generate it

Guess you like

Origin blog.csdn.net/liyp921210/article/details/129266442