{"id":9417,"date":"2021-08-23T07:00:08","date_gmt":"2021-08-22T22:00:08","guid":{"rendered":"https:\/\/blog.capilano-fw.com\/?p=9417"},"modified":"2021-07-21T03:27:59","modified_gmt":"2021-07-20T18:27:59","slug":"vue-plugin-%e3%81%a7%e3%82%b3%e3%83%b3%e3%83%9d%e3%83%bc%e3%83%8d%e3%83%b3%e3%83%88%e3%80%81%e3%83%9f%e3%83%83%e3%82%af%e3%82%b9%e3%82%a4%e3%83%b3%e3%80%81%e3%83%87%e3%82%a3%e3%83%ac%e3%82%af%e3%83%86","status":"publish","type":"post","link":"https:\/\/blog.capilano-fw.com\/?p=9417","title":{"rendered":"Vue Plugin \u3067\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3001\u30df\u30c3\u30af\u30b9\u30a4\u30f3\u3001\u30c7\u30a3\u30ec\u30af\u30c6\u30a3\u30d6\u3092\u3072\u3068\u307e\u3068\u3081\u306b\u3059\u308b"},"content":{"rendered":"<p>\u3055\u3066\u3055\u3066\u3001\u3053\u306e\u9593\u516c\u958b\u3057\u305f<strong>\u00a0<a href=\"https:\/\/blog.capilano-fw.com\/?p=9295\">Vue 3 \u3067\u30af\u30ea\u30c3\u30d7\u30dc\u30fc\u30c9\u306b\u30b3\u30d4\u30fc\u3067\u304d\u308b\u30dc\u30bf\u30f3\u3092\u3064\u304f\u308b<\/a> <\/strong>\u3068\u3044\u3046\u8a18\u4e8b\u304c\u4e88\u60f3\u3057\u3066\u3044\u305f\u3088\u308a\u3082\u591a\u304f\u30a2\u30af\u30bb\u30b9\u3044\u3057\u3066\u3044\u305f\u3060\u304d\u3001\uff08\u30c6\u30f3\u30b7\u30e7\u30f3\u304c\u4e0a\u304c\u3063\u305f\u306e\u3067\uff09\u4eca\u56de\u3082<code>Vue<\/code>\u306b\u95a2\u3059\u308b\u8a18\u4e8b\u3092\u304a\u5c4a\u3051\u3057\u307e\u3059\u3002\ud83d\ude02<\/p>\n<p>\u3068\u306f\u3044\u3048\u3001<code>Vue<\/code>\u3067\u307e\u3060\u8a18\u4e8b\u3068\u3057\u3066\u66f8\u3044\u3066\u3044\u306a\u3044\u8a71\u984c\u3068\u306a\u308b\u3068\u305d\u308c\u307b\u3069\u6570\u304c\u591a\u304f\u306f\u306a\u3044\u306e\u3067\u3059\u304c\u3001\u300c<strong>\u3072\u3068\u3064\u3084\u308a\u6b8b\u3057\u3066\u3044\u308b<\/strong>\u300d\u3053\u3068\u304c\u3042\u308a\u307e\u3057\u305f\u3002<\/p>\n<p>\u305d\u308c\u304c\u30fb\u30fb\u30fb\u30fb\u30fb\u30fb<\/p>\n<p><strong style=\"font-size: 35px;\">Vue \u30d7\u30e9\u30b0\u30a4\u30f3<\/strong><\/p>\n<p>\u3067\u3059\u3002<\/p>\n<p>\u300c<strong>Vue\u30d7\u30e9\u30b0\u30a4\u30f3<\/strong>\u300d\u3068\u306f\u3001\u30b7\u30f3\u30d7\u30eb\u306b\u8a00\u3046\u3068\u300c<strong>Vue\u672c\u4f53\u3092\u6539\u9020\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u308b<\/strong>\u300d\u6a5f\u80fd\u306e\u3053\u3068\u3067\u3059\u304c\u3001\u4eca\u56de\u306f\u4ee5\u4e0b\u306e\u3082\u306e\u3092\u4f5c\u3063\u3066\u307f\u305f\u3044\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<p>\u305d\u308c\u306f\u30fb\u30fb\u30fb\u30fb\u30fb\u30fb<\/p>\n<p><strong style=\"font-size: 35px;\">\u304a\u91d1\u306b\u95a2\u3059\u308b\u64cd\u4f5c\u3092\u7dcf\u5408\u7684\u306b\u5f15\u304d\u53d7\u3051\u3066\u304f\u308c\u308b<\/strong><\/p>\n<p>\u30d7\u30e9\u30b0\u30a4\u30f3\u3067\u3059\u3002<\/p>\n<p>\u4f8b\u3048\u3070\u3001\u901a\u5e38\u6570\u5b57\u306f\u30b1\u30bf\u304c\u591a\u304f\u306a\u308b\u3068\u898b\u306b\u304f\u304f\u306a\u308b\u305f\u3081\u3001\uff13\u30b1\u30bf\u305a\u3064\u300c\u30ab\u30f3\u30de\uff08,\uff09\u300d\u3092\u3064\u3051\u307e\u3059\u3002<\/p>\n<p><strong>\u4f8b\uff1a<\/strong> 1,000,000\u5186\uff08\ud83d\udc48\u767e\u4e07\u5186\u3067\u3059\u3002\u3064\u307e\u308a\u3001\u6708\u53ce\uff17\u6841\u3068\u3044\u3048\u3070100\u4e07\u5186\u4ee5\u4e0a\u7a3c\u3044\u3067\u308b\u3068\u3044\u3046\u3053\u3068\u306b\u306a\u308a\u307e\u3059\u306d\u3002\u30a6\u30e9\u30e4\u30de\u30b7\u30a4\ud83d\ude02\uff09<\/p>\n<p>\u307e\u305f\u3001\u304a\u91d1\u3092\u53d6\u308a\u6271\u3046\u5834\u5408\u3001\u8aa4\u89e3\u304c\u306a\u3044\u3088\u3046\u306b\u300c\uffe5\u300d\u3092\u3064\u3051\u305f\u308a\u300c\u25cf\u25cf\u5186\u300d\u3068\u8868\u8a18\u3059\u308b\u5834\u5408\u3082\u3042\u308a\u307e\u3059\u3002<\/p>\n<p>\u4eca\u56de\u306f\u305d\u3046\u3044\u3063\u305f\u300c\u304a\u91d1\u300d\u306b\u95a2\u3059\u308b\u64cd\u4f5c\u3092\u4ee5\u4e0b\uff13\u3064\u306e\u6a5f\u80fd\u3067\u7dcf\u5408\u7684\u306b\u3064\u304f\u308a\u3001<strong>\u30d7\u30e9\u30b0\u30a4\u30f3\u3068\u3057\u3066\u3072\u3068\u307e\u3068\u3081\u306b\u3057\u3066\u307f\u307e\u3059\u3002<\/strong><\/p>\n<ul>\n<li>\u6570\u5b57\u3092\u30ab\u30f3\u30de\u533a\u5207\u308a\u306b\u3059\u308b\u300c\u30df\u30c3\u30af\u30b9\u30a4\u30f3\u300d<\/li>\n<li>\u5165\u529b\u3059\u308b\u3068\u304d\u306f\u6570\u5b57\u3060\u3051\u3069\u3001\u30d5\u30a9\u30fc\u30ab\u30b9\u304c\u5916\u308c\u308b\u3068\u30ab\u30f3\u30de\u304c\u8868\u793a\u3055\u308c\u308b\u300c\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u300d<\/li>\n<li>\u8868\u793a\u3059\u308b\u6570\u5b57\u3092\u300c\u30ab\u30f3\u30de\u3064\u304d\u6570\u5b57\u300d\uff0b\u300c\u5186\u300d\u3067\u8868\u793a\u3059\u308b\u300c\u30c7\u30a3\u30ec\u30af\u30c6\u30a3\u30d6\u300d<\/li>\n<\/ul>\n<p>\u305c\u3072\u300c<strong>Vue\u30d7\u30e9\u30b0\u30a4\u30f3<\/strong>\u300d\u306e\u30a8\u30c3\u30bb\u30f3\u30b9\u3092\u4f53\u9a13\u3057\u3066\u3044\u305f\u3060\u3051\u308b\u3068\u5b09\u3057\u3044\u3067\u3059\u3002\ud83d\ude0a\u2728<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-6070 aligncenter\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2020\/03\/no_5.png\" alt=\"\" width=\"260\" height=\"320\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2020\/03\/no_5.png 260w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2020\/03\/no_5-244x300.png 244w\" sizes=\"auto, (max-width: 260px) 100vw, 260px\" \/>\u300c\u7d50\u5c40\u30d5\u30a1\u30a4\u30ca\u30f3\u30b7\u30e3\u30eb\u30d7\u30e9\u30f3\u30ca\u30fc\u306e\u8cc7\u683c\u3001<br \/>\n\u4f7f\u308f\u306a\u304b\u3063\u305f\u306a\u30fb\u30fb\u30fb\ud83d\ude2b\u300d<\/p>\n<p><strong>\u958b\u767a\u74b0\u5883\uff1a<\/strong> Vue 3<\/p>\n<h1>\u4f5c\u696d\u306e\u6d41\u308c<\/h1>\n<p>\u4f5c\u696d\u306e\u6d41\u308c\u3068\u3057\u3066\u306f\u3001\u307e\u305a\u306f\uff13\u3064\u306e\u6a5f\u80fd\u3092\u3072\u3068\u3064\u305a\u3064\u4f5c\u308a\u3001\u6700\u7d42\u7684\u306b\u305d\u308c\u3089\u3092\u300c<strong>\u30d7\u30e9\u30b0\u30a4\u30f3<\/strong>\u300d\u3067\u3072\u3068\u307e\u3068\u3081\u306b\u3057\u307e\u3059\u3002<\/p>\n<p>\u3067\u306f\u5b9f\u969b\u306b\u3084\u3063\u3066\u3044\u304d\u307e\u3057\u3087\u3046\u2757<\/p>\n<h1>\u6570\u5b57\u3092\uff13\u30b1\u30bf\u305a\u3064\u3067\u30ab\u30f3\u30de\u533a\u5207\u308a\u306b\u3059\u308b\u300c\u30df\u30c3\u30af\u30b9\u30a4\u30f3\u300d\u3092\u3064\u304f\u308b<\/h1>\n<p>\u3067\u306f\u307e\u305a\u306f\u3001\u6570\u5b57\u3092\u5165\u308c\u3066\u3042\u3052\u305f\u3089\u300c<strong>\uff13\u30b1\u30bf\u305a\u3064\u30ab\u30f3\u30de\u533a\u5207\u308a\u306b\u306a\u3063\u305f\u6587\u5b57\u5217<\/strong>\u300d\u304c\u30b2\u30c3\u30c8\u3067\u304d\u308b\u300c<strong>\u30df\u30c3\u30af\u30b9\u30a4\u30f3<\/strong>\u300d\u3092\u3064\u304f\u3063\u3066\u3044\u304d\u307e\u3059\u3002<\/p>\n<p>\u30df\u30c3\u30af\u30b9\u30a4\u30f3\u3068\u306f\u3001\u300c\u3042\u308b\u7279\u5b9a\u306e\u90e8\u5206\u3060\u3051\u3092\u5206\u96e2\u3067\u304d\u308b\u300d\u6a5f\u80fd\u306e\u3053\u3068\u3067\u3001\u76ee\u7684\u3068\u3057\u3066\u306f\u300c<strong>\u3042\u3063\u3061\u3067\u3082\u4f7f\u3046\u3057\u3001\u3053\u3063\u3061\u3067\u3082\u4f7f\u3046\u3002\u3058\u3083\u3042\u3001\u5171\u901a\u5316\u3057\u3068\u3051\u3070\u3001\u4f7f\u3044\u56de\u3057\u3067\u304d\u3066\u30e9\u30af\u3067\u304d\u308b\u3088\u306d\ud83d\udc4d<\/strong>\u300d\u3068\u3044\u3046\u3082\u306e\u3067\u3059\u3002<\/p>\n<p>\u5b9f\u969b\u306e\u30b3\u30fc\u30c9\u306f\u3053\u3061\u3089\u3067\u3059\u3002<\/p>\n<pre><strong>const priceMixin = {<\/strong>\r\n<strong>    methods: {<\/strong>\r\n<strong>        commify(price) {<\/strong>\r\n\r\n<strong>            return this.getPriceAsNumber(price).toLocaleString() +'\u5186'<\/strong>\r\n\r\n<strong>        },<\/strong>\r\n<strong>        getPriceAsNumber(price) { \/\/ \u6587\u5b57\u5217\u3067\u306f\u306a\u304f\u3001\u6570\u5b57\u3068\u3057\u3066\u91d1\u984d\u3092\u53d6\u5f97<\/strong>\r\n\r\n<strong>            price = price.toString().replace(\/[^0-9]+\/g, '') \/\/ \u6570\u5b57\u4ee5\u5916\u3092\u9664\u53bb<\/strong>\r\n<strong>            return parseInt(price);<\/strong>\r\n\r\n<strong>        }<\/strong>\r\n<strong>    }<\/strong>\r\n<strong>};<\/strong><\/pre>\n<p>\u3053\u306e\u4e2d\u306e\u30e1\u30a4\u30f3\u306f\u3082\u3061\u308d\u3093<code>commify()<\/code>\u3067\u3059\u3002<br \/>\n<code>replace()<\/code>\u3092\u4f7f\u3063\u3066\u30ab\u30f3\u30de\u3064\u304d\u6570\u5b57\u306b\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u304c\u3001\u30b7\u30f3\u30d7\u30eb\u306a\u306e\u3067\u3001\u4eca\u56de\u306f<code>toLocaleString()<\/code>\u3092\u4f7f\u3044\u307e\u3057\u305f\u3002<\/p>\n<p>\u307e\u305f\u3001\u88dc\u52a9\u7684\u306a<code>getPriceAsNumber()<\/code>\u306f\u3001\u300c<strong>\u6570\u5b57\u4ee5\u5916\u304c\u542b\u307e\u308c\u3066\u3044\u308b\u304b\u3082\u3057\u308c\u306a\u3044\u5024\u304b\u3089\u6570\u5b57\u3060\u3051\u3092\u629c\u304d\u51fa\u3059<\/strong>\u300d\u3068\u3044\u3046\u30e1\u30bd\u30c3\u30c9\u3067\u3059\u3002<\/p>\n<p>\u3061\u306a\u307f\u306b\u3001\u3053\u306e\u90e8\u5206\u306f\u5143\u3005<code>commify()<\/code>\u3072\u3068\u3064\u3060\u3051\u3067\u5b9f\u88c5\u3057\u3066\u3044\u307e\u3057\u305f\u304c\u3001\u4ed6\u306e\u5834\u6240\u3067\u540c\u3058\u3088\u3046\u306a\u51e6\u7406\u304c\u5fc5\u8981\u3068\u5206\u304b\u308a\u3001\u308f\u3056\u308f\u3056\u5206\u5272\u3057\u307e\u3057\u305f\u3002<\/p>\n<p>\u3053\u3046\u3059\u308b\u3053\u3068\u3067\u3001<strong>\u540c\u3058\u30b3\u30fc\u30c9\u3092\u91cd\u8907\u3055\u305b\u308b\u3053\u3068\u304c\u306a\u304f\u306a\u308b<\/strong>\u306e\u3067\u30b3\u30fc\u30c9\u91cf\u304c\u6e1b\u308a\u3001\u3055\u3089\u306b\u3001\u3082\u3057\u4f55\u304b\u3042\u3063\u3066\u3082\u3053\u3053\u3060\u3051\u4fee\u6b63\u3059\u308c\u3070OK\uff08\uff1d\u3064\u307e\u308a\u30e9\u30af\uff09\u3068\u3044\u3046\u3053\u3068\u306b\u306a\u308a\u307e\u3059 \ud83d\udc4d\u2728<\/p>\n<p>\u4f7f\u3044\u65b9\u306f\u6b21\u306e\u3068\u304a\u308a\u3067\u3059\u3002<\/p>\n<pre><strong>Vue.createApp({<\/strong>\r\n<strong>    mounted() {<\/strong>\r\n\r\n<strong>        console.log(this.commify(1000000)); \/\/ 1,000,000\u5186<\/strong>\r\n\r\n<strong>    }<\/strong>\r\n<strong>})<\/strong>\r\n<strong>.mixin(priceMixin) \/\/ \ud83d\udc48 \u3053\u3053\u3067\u30bb\u30c3\u30c8\u3057\u3066\u3044\u307e\u3059\u3002<\/strong>\r\n<strong>.mount('#app');<\/strong><\/pre>\n<h1>\u5165\u529b\u3059\u308b\u3068\u304d\u306f\u6570\u5b57\u3060\u3051\u3069\u3001\u30d5\u30a9\u30fc\u30ab\u30b9\u304c\u5916\u308c\u308b\u3068\u30ab\u30f3\u30de\u304c\u8868\u793a\u3055\u308c\u308b\u300c\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u300d\u3092\u3064\u304f\u308b<\/h1>\n<p>\u3067\u306f\u3001\u7d9a\u3044\u3066\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3067\u3059\u3002<\/p>\n<p>\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u306e\u6761\u4ef6\u306f\u6b21\u306e\uff12\u3064\u3067\u3059\u3002<\/p>\n<ul>\n<li>\u30d5\u30a9\u30fc\u30ab\u30b9\u304c\u3042\u305f\u308b\u3068 type=&#8221;number&#8221; \u306e\u6570\u5b57\u5165\u529b\u306b\u306a\u308b<\/li>\n<li>\u30d5\u30a9\u30fc\u30ab\u30b9\u304c\u5916\u308c\u308b\u3068\uff13\u30b1\u30bf\u306e\u30ab\u30f3\u30de\u533a\u5207\u308a\u306b\u306a\u308b<\/li>\n<\/ul>\n<p>\u3067\u306f\u3001\u5b9f\u969b\u306e\u30b3\u30fc\u30c9\u3067\u3059\u3002<\/p>\n<pre><strong>const priceInputComponent = {<\/strong>\r\n<strong>    mixins: [priceMixin],<\/strong>\r\n<strong>    props: {<\/strong>\r\n<strong>        modelValue: Number<\/strong>\r\n<strong>    },<\/strong>\r\n<strong>    data() {<\/strong>\r\n<strong>        return {<\/strong>\r\n<strong>            price: '',<\/strong>\r\n<strong>            inputType: 'text',<\/strong>\r\n<strong>            isFocusing: false<\/strong>\r\n<strong>        }<\/strong>\r\n<strong>    },<\/strong>\r\n<strong>    methods: {<\/strong>\r\n<strong>        onInput() {<\/strong>\r\n\r\n<strong>            this.$emit('update:modelValue', this.numberPrice); \/\/ \u5909\u66f4\u3057\u305f\u5024\u3092\u547c\u3073\u51fa\u3057\u5143\u306eVue\u306b\u4f1d\u3048\u308b<\/strong>\r\n\r\n<strong>        }<\/strong>\r\n<strong>    },<\/strong>\r\n<strong>    watch: {<\/strong>\r\n<strong>        modelValue: {<\/strong>\r\n<strong>            immediate: true,<\/strong>\r\n<strong>            handler(value) {<\/strong>\r\n\r\n<strong>                this.price = value;<\/strong>\r\n\r\n<strong>            }<\/strong>\r\n<strong>        },<\/strong>\r\n<strong>        isFocusing: {<\/strong>\r\n<strong>            immediate: true,<\/strong>\r\n<strong>            handler(value) {<\/strong>\r\n\r\n<strong>                this.inputType = (value === true)<\/strong>\r\n<strong>                    ? 'number'<\/strong>\r\n<strong>                    : 'text';<\/strong>\r\n\r\n<strong>                Vue.nextTick(() =&gt; {<\/strong>\r\n\r\n<strong>                    this.price = (value === true)<\/strong>\r\n<strong>                        ? this.numberPrice<\/strong>\r\n<strong>                        : this.commify(this.numberPrice);<\/strong>\r\n\r\n<strong>                });<\/strong>\r\n<strong>            }<\/strong>\r\n<strong>        }<\/strong>\r\n<strong>    },<\/strong>\r\n<strong>    computed: {<\/strong>\r\n<strong>        numberPrice() {<\/strong>\r\n\r\n<strong>            return this.getPriceAsNumber(this.price);<\/strong>\r\n\r\n<strong>        }<\/strong>\r\n<strong>    },<\/strong>\r\n<strong>    template: `<\/strong>\r\n<strong>        &lt;input<\/strong>\r\n<strong>            :type=\"inputType\"<\/strong>\r\n<strong>            v-model=\"price\"<\/strong>\r\n<strong>            @focus=\"isFocusing=true\"<\/strong>\r\n<strong>            @blur=\"isFocusing=false\"<\/strong>\r\n<strong>            @input=\"onInput\"&gt;<\/strong>\r\n<strong>    `<\/strong>\r\n<strong>};<\/strong><\/pre>\n<p>\u3053\u306e\u4e2d\u3067\u91cd\u8981\u306a\u306e\u306f\u3001\u30c7\u30fc\u30bf\u304c\u5165\u3063\u3066\u304f\u308b<code>props<\/code>\u3068\u51fa\u3066\u3044\u304f<code>this.$emit()<\/code>\u306e\u90e8\u5206\u3067\u3059\u3002\u306a\u305c\u306a\u3089\u3001\u76f4\u63a5<code>props<\/code>\u3092\u5909\u66f4\u3059\u308b\u3068\u30a8\u30e9\u30fc\u304c\u51fa\u3066\u3057\u307e\u3046\u304b\u3089\u3067\u3059\u3002<\/p>\n<p>\u8a73\u3057\u304f\u306f\u4ee5\u4e0b\u306e\u30da\u30fc\u30b8\u3092\u3054\u89a7\u304f\u3060\u3055\u3044\u3002<\/p>\n<p><strong>\ud83d\udcdd \u53c2\u8003\u30da\u30fc\u30b8\uff1a<\/strong>\u00a0<a href=\"https:\/\/blog.capilano-fw.com\/?p=7622\">Vue\u306e\u5b9a\u756a\u30a8\u30e9\u30fc\u300cAvoid mutating a prop directly\u2026\u300d\u306e\u539f\u56e0\u3068\u5bfe\u51e6\u65b9\u6cd5<\/a><\/p>\n<p>\u4f7f\u3044\u65b9\u306f\u6b21\u306e\u3068\u304a\u308a\u3067\u3059\u3002<\/p>\n<pre>Vue.createApp({\r\n<strong>    data() {<\/strong>\r\n<strong>        return {<\/strong>\r\n<strong>            price: 10000 \/\/ \ud83d\udc48 \u3053\u3053\u304c\u521d\u671f\u5024\u306b\u306a\u308a\u307e\u3059<\/strong>\r\n<strong>        }<\/strong>\r\n<strong>    },<\/strong>\r\n\r\n    \/\/ \u7701\u7565\r\n\r\n})\r\n<strong>.component('v-price-input', priceInputComponent) \/\/ \ud83d\udc48 \u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3092\u30bb\u30c3\u30c8\u3057\u3066\u307e\u3059<\/strong>\r\n.mount('#app');<\/pre>\n<p>\u305d\u3057\u3066<code>HTML<\/code>\u306f\u3053\u3046\u306a\u308a\u307e\u3059\u3002<\/p>\n<pre>&lt;div id=\"app\"&gt;\r\n\r\n    <strong>&lt;v-price-input v-model=\"price\"&gt;&lt;\/v-price-input&gt;<\/strong>\r\n    &lt;br&gt;\r\n    \u73fe\u5728\u306e\u5185\u90e8\u7684\u306a\u5024: &lt;span v-text=\"price\"&gt;&lt;\/span&gt;\r\n\r\n&lt;\/div&gt;<\/pre>\n<h1>\u8868\u793a\u3059\u308b\u6570\u5b57\u3092\u300c\u30ab\u30f3\u30de\u3064\u304d\u6570\u5b57\u300d\uff0b\u300c\u5186\u300d\u3067\u8868\u793a\u3059\u308b\u300c\u30c7\u30a3\u30ec\u30af\u30c6\u30a3\u30d6\u300d\u3092\u3064\u304f\u308b<\/h1>\n<p>\u6700\u5f8c\u306b\u30c7\u30a3\u30ec\u30af\u30c6\u30a3\u30d6\u3067\u3059\u3002<\/p>\n<p>\u30c7\u30a3\u30ec\u30af\u30c6\u30a3\u30d6\u306f\u3001\u3088\u304f\u4f7f\u3046<code>v-if<\/code>\u3084<code>v-for<\/code>\u306e\u3088\u3046\u306bHTML\u30bf\u30b0\u306b\u3064\u3051\u3066\u3044\u308d\u3044\u308d\u306a\u64cd\u4f5c\u304c\u3067\u304d\u308b\u6a5f\u80fd\u3067\u3059\u3002\u4eca\u56de\u306f\u6570\u5b57\u3060\u3051\u3092\u8868\u793a\u3057\u3066\u3044\u308b\u90e8\u5206\u3092\u81ea\u52d5\u7684\u306b\u300c<strong>\u30ab\u30f3\u30de\u3064\u304d\u6570\u5b57<\/strong>\u300d\u306b\u3057\u3066\u307f\u307e\u3059\u3002<\/p>\n<p>\u5b9f\u969b\u306e\u30b3\u30fc\u30c9\u306f\u3053\u3061\u3089\u3002<\/p>\n<pre><strong>const priceDirective = {<\/strong>\r\n<strong>    updated(el, binding) {<\/strong>\r\n\r\n<strong>        el.innerText = binding.instance.commify(el.innerText);<\/strong>\r\n\r\n<strong>    },<\/strong>\r\n<strong>    mounted(el, binding) {<\/strong>\r\n\r\n<strong>        el.innerText = binding.instance.commify(el.innerText);<\/strong>\r\n\r\n<strong>    }<\/strong>\r\n<strong>};<\/strong><\/pre>\n<p>\u3053\u306e\u4e2d\u306e<code>binding.instance<\/code>\u306f\u547c\u3073\u51fa\u3057\u5143\uff08\u3064\u307e\u308a<code>Vue<\/code>\u306e\uff09\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u305d\u306e\u305f\u3081\u3001\u30df\u30c3\u30af\u30b9\u30a4\u30f3\u3067\u4f7f\u3048\u308b\u3088\u3046\u306b\u3057\u305f<code>commify()<\/code>\u306b\u30a2\u30af\u30bb\u30b9\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u308b\u308f\u3051\u3067\u3059\u3002<\/p>\n<p>\u4f7f\u3044\u65b9\u306f\u3053\u3046\u306a\u308a\u307e\u3059\u3002<\/p>\n<pre>Vue.createApp({\r\n    data() {\r\n        return {\r\n            price: 10000,\r\n            <strong>price2: 10000, \/\/ \ud83d\udc48 \u3053\u3053\u3092\u8ffd\u52a0\u3057\u307e\u3057\u305f\u3002<\/strong>\r\n        }\r\n    },\r\n    \r\n    \/\/ \u7701\u7565\r\n\r\n})\r\n\/\/ \u7701\u7565\r\n<strong>.directive('price', priceDirective) \/\/ \ud83d\udc48 \u3053\u3053\u3092\u8ffd\u52a0\u3057\u307e\u3057\u305f<\/strong>\r\n.mount('#app');<\/pre>\n<p>\u305d\u3057\u3066\u3001HTML\u5074\u306f\u3053\u3046\u306a\u308a\u307e\u3059\u3002<\/p>\n<pre>&lt;div v-text=\"price2\"<strong> v-price<\/strong>&gt;&lt;\/div&gt;\r\n&lt;button @click=\"price2=500000\"&gt;\u5024\u3092\u5909\u66f4\u3059\u308b&lt;\/button&gt;<\/pre>\n<p><code>updated<\/code>\u3092\u8a2d\u5b9a\u3057\u3066\u3044\u308b\u306e\u3067\u3001\u30dc\u30bf\u30f3\u3092\u30af\u30ea\u30c3\u30af\u3057\u3066<code>price2<\/code>\u306e\u4e2d\u8eab\u304c\u5909\u66f4\u306b\u306a\u3063\u3066\u3082\u540c\u3058\u304f\u300c<strong>\u30ab\u30f3\u30de\u3064\u304d\u6570\u5b57<\/strong>\u300d\u3067\u8868\u793a\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<h1>Vue \u30d7\u30e9\u30b0\u30a4\u30f3\u3092\u3064\u304f\u308b<\/h1>\n<p>\u3067\u306f\u3001\u3053\u3053\u307e\u3067\u3067\u3064\u304f\u3063\u3066\u304d\u305f\uff13\u3064\u306e\u6a5f\u80fd\u3092\u3072\u3068\u307e\u3068\u3081\u306b\u3057\u3066\u30d7\u30e9\u30b0\u30a4\u30f3\u5316\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u5b9f\u969b\u306e\u30b3\u30fc\u30c9\u306f\u3053\u3061\u3089\u3067\u3059\u3002<\/p>\n<pre>const pricePlugin = {\r\n    <strong>install(app) {<\/strong>\r\n\r\n        \/\/ \u30df\u30c3\u30af\u30b9\u30a4\u30f3\r\n        <strong>app.mixin<\/strong>({\r\n            methods: {\r\n                commify(price) {\r\n\r\n                    return this.getPriceAsNumber(price).toLocaleString() +'\u5186'\r\n\r\n                },\r\n                getPriceAsNumber(price) {\r\n\r\n                    price = price.toString().replace(\/[^0-9]+\/g, '')\r\n                    return parseInt(price);\r\n\r\n                }\r\n            }\r\n        });\r\n\r\n        \/\/ \u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\r\n        <strong>app.component<\/strong>('v-price-input', {\r\n\r\n            <strong>\/\/ \ud83d\udc48 \u3053\u3053\u306e mixins: [priceMixin], \u306f\u4e0d\u8981\u306b\u306a\u308a\u307e\u3057\u305f<\/strong>\r\n\r\n            props: {\r\n                modelValue: Number\r\n            },\r\n            data() {\r\n                return {\r\n                    price: '',\r\n                    inputType: 'text',\r\n                    isFocusing: false\r\n                }\r\n            },\r\n            methods: {\r\n                onInput() {\r\n\r\n                    this.$emit('update:modelValue', this.numberPrice);\r\n\r\n                }\r\n            },\r\n            watch: {\r\n                modelValue: {\r\n                    immediate: true,\r\n                    handler(value) {\r\n\r\n                        this.price = value;\r\n\r\n                    }\r\n                },\r\n                isFocusing: {\r\n                    immediate: true,\r\n                    handler(value) {\r\n\r\n                        this.inputType = (value === true)\r\n                            ? 'number'\r\n                            : 'text';\r\n\r\n                        Vue.nextTick(() =&gt; {\r\n\r\n                            this.price = (value === true)\r\n                                ? this.numberPrice\r\n                                : this.commify(this.numberPrice);\r\n\r\n                        });\r\n                    }\r\n                }\r\n            },\r\n            computed: {\r\n                numberPrice() {\r\n\r\n                    return this.getPriceAsNumber(this.price);\r\n\r\n                }\r\n            },\r\n            template: `\r\n                &lt;input\r\n                    :type=\"inputType\"\r\n                    v-model=\"price\"\r\n                    @focus=\"isFocusing=true\"\r\n                    @blur=\"isFocusing=false\"\r\n                    @input=\"onInput\"&gt;\r\n            `\r\n        });\r\n\r\n        \/\/ \u30c7\u30a3\u30ec\u30af\u30c6\u30a3\u30d6\r\n        <strong>app.directive<\/strong>('price', {\r\n            updated(el, binding) {\r\n\r\n                el.innerText = binding.instance.commify(el.innerText);\r\n\r\n            },\r\n            mounted(el, binding) {\r\n\r\n                el.innerText = binding.instance.commify(el.innerText);\r\n\r\n            }\r\n        });\r\n\r\n    <strong>}<\/strong>\r\n};<\/pre>\n<p>\u6b63\u76f4\u306a\u3068\u3053\u308d\u3001\u3053\u308c\u307e\u3067\u306e\uff13\u3064\u3092\u307b\u307c\u30b3\u30d4\u30fc\uff06\u30da\u30fc\u30b9\u30c8\u3057\u3066\u3044\u308b\u3060\u3051\u3067\u3059\u304c\u3001\u5c11\u3057\u3060\u3051\u30a4\u30ec\u30ae\u30e5\u30e9\u30fc\u306a\u90e8\u5206\u3082\u3042\u308a\u307e\u3059\u3002<\/p>\n<p>\u305d\u308c\u304c\u3001\u4ee5\u4e0b\u306e\u300c<strong>\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u5185\u3067\u306e\u30df\u30c3\u30af\u30b9\u30a4\u30f3\u547c\u3073\u51fa\u3057<\/strong>\u300d\u304c\u4e0d\u8981\u306b\u306a\u3063\u305f\u3053\u3068\u3067\u3059\u3002<\/p>\n<pre><strong>mixins: [priceMixin]<\/strong><\/pre>\n<p>\u306a\u305c\u4e0d\u8981\u306b\u306a\u308b\u304b\u3068\u3044\u3046\u3068\u3001<code>app.mixin()<\/code>\u306f<code>Vue<\/code>\u672c\u4f53\u3060\u3051\u3067\u306a\u304f\u3001\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3067\u3082\u6709\u52b9\u306b\u306a\u308b\u304b\u3089\u306a\u3093\u3067\u3059\u306d\u3002<\/p>\n<p>\u4f7f\u3044\u65b9\u306f\u3053\u3046\u306a\u308a\u307e\u3059\u3002<\/p>\n<pre>Vue.createApp({\r\n\r\n    \/\/ \u7701\u7565\r\n\r\n})\r\n<strong>.use(pricePlugin) \/\/ \ud83d\udc48 \u3053\u3053\u3092\u8ffd\u52a0\u3057\u307e\u3057\u305f<\/strong>\r\n.mount('#app');<\/pre>\n<p>\u306f\u3044\u2757<\/p>\n<p>\u305a\u3044\u3076\u3093\u30b9\u30c3\u30ad\u30ea\u3057\u307e\u3057\u305f\u3002<br \/>\n\u3053\u308c\u3082\u30d7\u30e9\u30b0\u30a4\u30f3\u306e\u3044\u3044\u3068\u3053\u308d\u3067\u3059\u306d\u3002<\/p>\n<h1>\u3061\u306a\u307f\u306b\uff1a \u30d7\u30e9\u30b0\u30a4\u30f3\u306e\u30aa\u30d7\u30b7\u30e7\u30f3<\/h1>\n<p>\u5b9f\u306f\u30d7\u30e9\u30b0\u30a4\u30f3\u306b\u306f<code>options<\/code>\u3068\u3044\u3046\u30d1\u30e9\u30e1\u30fc\u30bf\u3092\u6307\u5b9a\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>\u305d\u306e\u305f\u3081\u3001\u4eca\u56de\u306f\u300c<strong>\u5186<\/strong>\u300d\u3092\u300c<strong>\u30c9\u30eb<\/strong>\u300d\u3084\u300c<strong>\u30e6\u30fc\u30ed<\/strong>\u300d\u306a\u3069\u81ea\u7531\u306b\u5909\u66f4\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p>\u3068\u8a00\u3063\u3066\u3082\u30b3\u30fc\u30c9\u306f\u4ee5\u4e0b\u306e\u90e8\u5206\u3092\u5909\u66f4\u3059\u308b\u3060\u3051\u3067OK\u3067\u3059\u3002<\/p>\n<pre>const pricePlugin = {\r\n    install(app, <strong>options<\/strong>) {\r\n\r\n        <strong>const currency = options.currency || '\u5186'; \/\/ \u6307\u5b9a\u304c\u306a\u3044\u5834\u5408\u306f\u300c\u5186\u300d\u3092\u3064\u304b\u3046<\/strong>\r\n\r\n        app.mixin({\r\n            methods: {\r\n                commify(price) {\r\n\r\n                    return this.getPriceAsNumber(price).toLocaleString() + <strong>currency<\/strong>\r\n\r\n                },\r\n\r\n\/\/ \u7701\u7565<\/pre>\n<p>\u305d\u3057\u3066\u3001\u4f7f\u3044\u65b9\u306f\u3053\u3046\u306a\u308a\u307e\u3059\u3002<\/p>\n<pre>Vue.createApp({\r\n\r\n    \/\/ \u7701\u7565\r\n\r\n})\r\n.use(pricePlugin, {\r\n    <strong>currency: '\u30c9\u30eb' \/\/ \ud83d\udc48 \u3053\u3053\u3092\u8ffd\u52a0\u3057\u307e\u3057\u305f<\/strong>\r\n})\r\n.mount('#app');<\/pre>\n<p>\u3053\u308c\u3067\u3001\u5168\u3066\u30c9\u30eb\u8868\u8a18\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<h1>\u30c7\u30e2\u30da\u30fc\u30b8\u3092\u7528\u610f\u3057\u307e\u3057\u305f<\/h1>\n<p>\u4eca\u56de\u306e\u30d7\u30e9\u30b0\u30a4\u30f3\u3067\u5b9f\u88c5\u3057\u305f\u5185\u5bb9\u3092\u30c7\u30e2\u3068\u3057\u3066\u516c\u958b\u3057\u307e\u3057\u305f\u3002<br \/>\n\u305c\u3072\u53c2\u8003\u306b\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n<p>\ud83d\udcdd<a href=\"https:\/\/demo-laravel8x.capilano-fw.com\/vue_plugin\" target=\"_blank\" rel=\"noopener\"> \u30c7\u30e2\u30da\u30fc\u30b8<\/a><\/p>\n<h1>\u4f01\u696d\u69d8\u3078\u306e\u3054\u63d0\u6848<\/h1>\n<p>\u30d7\u30e9\u30b0\u30a4\u30f3\u5316\u306e\u6700\u5927\u306e\u30e1\u30ea\u30c3\u30c8\u306f\u300c<strong>\u958b\u767a\u52b9\u7387\u306e\u5411\u4e0a<\/strong>\u300d\u3067\u3059\u3002<\/p>\n<p>\u7e70\u308a\u8fd4\u3057\u4f7f\u3046\u30b3\u30fc\u30c9\u3092\u30d7\u30e9\u30b0\u30a4\u30f3\u5316\u3057\u3066\u304a\u3051\u3070\u3001\u8907\u6570\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3067\u5171\u901a\u3057\u3066\u3064\u304b\u3048\u308b\u305f\u3081\u3001\u4f5c\u696d\u3059\u308b\u90e8\u5206\u3092\u6e1b\u3089\u3059\u3053\u3068\u304c\u3067\u304d\u308b\u304b\u3089\u3067\u3059\u3002<\/p>\n<p>\u307e\u305f\u3001\u5171\u901a\u3059\u308b\u90e8\u5206\u3092\u5c11\u3057\u305a\u3064\u8ffd\u52a0\u3057\u3066\u3044\u3051\u3070\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u91cd\u306d\u308b\u3054\u3068\u306b\u300c<strong>\u958b\u767a\u3059\u308b\u5fc5\u8981\u304c\u306a\u3044<\/strong>\u300d\u90e8\u5206\u304c\u5897\u3048\u3066\u3044\u304f\u3053\u3068\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n<p>\u305f\u3068\u3048\u3070\u3001\u8acb\u6c42\u66f8\u756a\u53f7\u306a\u3069\u4f1a\u793e\u72ec\u81ea\u306e\u30d5\u30a9\u30fc\u30de\u30c3\u30c8\u3092\u300c<strong>ourCompanyPlugin<\/strong>\u300d\u3068\u3044\u3063\u305f\u540d\u524d\u3067\u30d7\u30e9\u30b0\u30a4\u30f3\u5316\u3057\u3066\u304a\u3051\u3070\u3001\u6b21\u56de\u304b\u3089\u306f\u30d7\u30e9\u30b0\u30a4\u30f3\u3092\u30b3\u30d4\u30fc\u3057\u3066\u547c\u3073\u51fa\u3059\u3060\u3051\u3067\u4f7f\u3048\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3059\u3002\uff08\u30d7\u30e9\u30b0\u30a4\u30f3\u3092<code>git<\/code>\u3067\u7ba1\u7406\u3057\u3066\u304a\u304f\u3068\u3055\u3089\u306b\u4f7f\u3044\u52dd\u624b\u3092\u3088\u304f\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\uff09<\/p>\n<p>\u307e\u305f\u3001\u4eca\u56de\u306f<code>Vue<\/code>\u306e\u8a71\u984c\u3067\u3057\u305f\u304c\u3001\u3053\u308c\u306f<code>PHP<\/code>\u3084<code>Python<\/code>\u306a\u3069\u5225\u8a00\u8a9e\u3067\u3082\u3042\u3063\u3066\u3082\u540c\u69d8\u3067\u3059\u3002<\/p>\n<p>\u3082\u3057\u4f55\u304b\u305d\u3046\u3044\u3063\u305f\u3054\u5e0c\u671b\u304c\u3054\u3056\u3044\u307e\u3057\u305f\u3089\u3001\u3044\u3064\u3067\u3082\u304a\u6c17\u8efd\u306b\u3054\u76f8\u8ac7\u304f\u3060\u3055\u3044\u3002\u305c\u3072\u3088\u308d\u3057\u304f\u304a\u9858\u3044\u3044\u305f\u3057\u307e\u3059\u3002m(_ _)m<\/p>\n<h1>\u304a\u308f\u308a\u306b<\/h1>\n<p>\u3068\u3044\u3046\u3053\u3068\u3067\u3001\u4eca\u56de\u306f<code>Vue<\/code>\u30d7\u30e9\u30b0\u30a4\u30f3\u3092\u3064\u304f\u308b\u3053\u3068\u3067\u3001\u300c<strong>\u30df\u30c3\u30af\u30b9\u30a4\u30f3<\/strong>\u300d\u300c<strong>\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8<\/strong>\u300d\u300c<strong>\u30c7\u30a3\u30ec\u30af\u30c6\u30a3\u30d6<\/strong>\u300d\u306e\uff13\u3064\u3092\u3072\u3068\u307e\u3068\u3081\u306b\u3057\u3066\u307f\u307e\u3057\u305f\u3002<\/p>\n<p>\u3082\u3061\u308d\u3093\u3001\u305d\u308c\u305e\u308c\u5358\u4f53\u3067\u7528\u610f\u3057\u3066\u304a\u3051\u3070\u4f7f\u3044\u56de\u3057\u304c\u3067\u304d\u308b\u306e\u3067\u3001\u5fc5\u305a\u30d7\u30e9\u30b0\u30a4\u30f3\u5316\u3059\u308b\u5fc5\u8981\u306f\u3042\u308a\u307e\u305b\u3093\u304c\u3001\u4f3c\u305f\u5185\u5bb9\u306e\u3082\u306e\u304c\u8907\u6570\u5b58\u5728\u3057\u3066\u3044\u308b\u5834\u5408\u306f\u3001\u3072\u3068\u307e\u3068\u3081\u306b\u3057\u3066\u304a\u3051\u3070\u7ba1\u7406\u304c\u30e9\u30af\u306b\u306a\u308b\u3068\u601d\u3044\u307e\u3059\u3002<\/p>\n<p>\u3061\u306a\u307f\u306b\u4eca\u56de\u306f\u89e6\u308c\u307e\u305b\u3093\u3067\u3057\u305f\u304c\u3001\u30d7\u30e9\u30b0\u30a4\u30f3\u3092\u4f7f\u3046\u3068<code>data()<\/code>\u306e\u300c<strong>\u521d\u671f\u5909\u6570<\/strong>\u300d\u3092\u53ef\u5909\u3067\u30bb\u30c3\u30c8\u3059\u308b\u3053\u3068\u3082\u3067\u304d\u307e\u3059\u3002<\/p>\n<p>\u4f8b\u3048\u3070\u3053\u3093\u306a\u30ab\u30f3\u30b8\u3067\u3059\u3002<\/p>\n<pre><strong>const dynamicDataPlugin = {<\/strong>\r\n<strong>    install(app) {<\/strong>\r\n\r\n<strong>        let dynamicData = {};<\/strong>\r\n\r\n<strong>        if(Date.now() % 2 === 0) {<\/strong>\r\n\r\n<strong>            dynamicData = {<\/strong>\r\n<strong>                key1: '',<\/strong>\r\n<strong>            };<\/strong>\r\n\r\n<strong>        } else {<\/strong>\r\n\r\n<strong>            dynamicData = {<\/strong>\r\n<strong>                key2: '',<\/strong>\r\n<strong>            };<\/strong>\r\n\r\n<strong>        }<\/strong>\r\n\r\n<strong>        app.mixin({<\/strong>\r\n<strong>            data() {<\/strong>\r\n<strong>                return dynamicData; \/\/ \u3053\u3053\u306f\u56fa\u5b9a\u3067\u306f\u306a\u304f\u306a\u308b<\/strong>\r\n<strong>            }<\/strong>\r\n<strong>        })<\/strong>\r\n\r\n<strong>    }<\/strong>\r\n<strong>};<\/strong><\/pre>\n<p>\u3053\u3093\u306a\u30ab\u30f3\u30b8\u3067<code>Vue<\/code>\u672c\u4f53\u3092\u3044\u308d\u3044\u308d\u3068\u6539\u9020\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u306e\u3067\u3001\u305c\u3072\u7686\u3055\u3093\u3082\u3084\u3063\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u306d\u3002<\/p>\n<p>\u3067\u306f\u3067\u306f\u301c\u2757<\/p>\n<p style=\"text-align: center;\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-6068 aligncenter\" src=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2020\/03\/no_12.png\" alt=\"\" width=\"226\" height=\"320\" srcset=\"https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2020\/03\/no_12.png 226w, https:\/\/blog.capilano-fw.com\/wp-content\/uploads\/2020\/03\/no_12-212x300.png 212w\" sizes=\"auto, (max-width: 226px) 100vw, 226px\" \/>\u300c\u304a\u5ba2\u3055\u3093\u306b\u3044\u305f\u3060\u3044\u305f<br \/>\n\u304a\u4e2d\u5143\u306e\u30d3\u30fc\u30eb<br \/>\n\u30a6\u30de\u30a6\u30de\u3067\u3059\ud83c\udf7a\u2728\u300d<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u3055\u3066\u3055\u3066\u3001\u3053\u306e\u9593\u516c\u958b\u3057\u305f\u00a0Vue 3 \u3067\u30af\u30ea\u30c3\u30d7\u30dc\u30fc\u30c9\u306b\u30b3\u30d4\u30fc\u3067\u304d\u308b\u30dc\u30bf\u30f3\u3092\u3064\u304f\u308b \u3068\u3044\u3046\u8a18\u4e8b\u304c\u4e88\u60f3\u3057\u3066\u3044\u305f\u3088\u308a\u3082\u591a\u304f\u30a2\u30af\u30bb\u30b9\u3044\u3057\u3066\u3044\u305f\u3060\u304d\u3001\uff08\u30c6\u30f3\u30b7\u30e7\u30f3\u304c\u4e0a\u304c &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/blog.capilano-fw.com\/?p=9417\" class=\"more-link\"><span class=\"screen-reader-text\">&#8220;Vue Plugin \u3067\u30b3\u30f3\u30dd\u30fc\u30cd\u30f3\u30c8\u3001\u30df\u30c3\u30af\u30b9\u30a4\u30f3\u3001\u30c7\u30a3\u30ec\u30af\u30c6\u30a3\u30d6\u3092\u3072\u3068\u307e\u3068\u3081\u306b\u3059\u308b&#8221; \u306e<\/span>\u7d9a\u304d\u3092\u8aad\u3080<\/a><\/p>\n","protected":false},"author":1,"featured_media":9426,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[12],"tags":[239],"class_list":["post-9417","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-vue-js","tag-239"],"_links":{"self":[{"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/posts\/9417","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=9417"}],"version-history":[{"count":9,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/posts\/9417\/revisions"}],"predecessor-version":[{"id":9428,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/posts\/9417\/revisions\/9428"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=\/wp\/v2\/media\/9426"}],"wp:attachment":[{"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=9417"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=9417"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.capilano-fw.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=9417"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}