{"id":769,"date":"2021-06-27T00:19:20","date_gmt":"2021-06-26T16:19:20","guid":{"rendered":"http:\/\/www.eolstudy.com\/?p=769"},"modified":"2021-06-27T09:30:41","modified_gmt":"2021-06-27T01:30:41","slug":"vue-js-typescript%ef%bc%9aclass-style-component-%e6%b7%bb%e5%8a%a0-static-%e5%b1%9e%e6%80%a7","status":"publish","type":"post","link":"https:\/\/www.eolstudy.com\/index.php\/2021\/06\/recommendation\/769\/","title":{"rendered":"Vue.js + TypeScript\uff1aclass style component \u6dfb\u52a0 static \u5c5e\u6027"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">Vue Router \u7684 Magic String<\/h2>\n\n\n\n<p>VueRouter \u7c7b\u7684\u6784\u9020\u51fd\u6570\u63a5\u53d7\u4e00\u4e2a\u5305\u542b <code data-enlighter-language=\"typescript\" class=\"EnlighterJSRAW\">routes: Array&lt;RouterConfig&gt;<\/code> \u5c5e\u6027\u7684\u5bf9\u8c61\u4f5c\u4e3a\u53c2\u6570\uff0c\u4e00\u822c\u6765\u8bf4 routes \u8fd9\u6837\u5b9a\u4e49\uff1a<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">import SomeComponent from 'path\/to\/component.vue'\n\nconst routes: Array&lt;RouteConfig> = [\n  {\n    path: 'some-path',\n    name: 'SomeComponentName',\n    component: SomeComponent\n  }\n  \/\/ ...\n]<\/pre>\n\n\n\n<p>\u5728\u4f7f\u7528 Vue Router \u65f6\uff0c\u5982\u679c\u8981\u8df3\u8f6c\u5230\u67d0\u4e2a\u754c\u9762\uff0c\u76f4\u63a5\u5c06 <code>&lt;router-link&gt;<\/code> \u6807\u7b7e\u7684 <code>to<\/code> attribute \u7ed1\u5b9a\u5230 <code data-enlighter-language=\"typescript\" class=\"EnlighterJSRAW\">{ name: 'SomeComponentName' }<\/code>\uff0c\u6216\u5728\u7ec4\u4ef6\u7684\u65b9\u6cd5\u4e2d <code data-enlighter-language=\"typescript\" class=\"EnlighterJSRAW\">this.$router.push({ name: 'SomeComponentName' })<\/code> \u5373\u53ef\u3002\u8fd9\u6837\u5904\u7406\u53ea\u9700\u8981\u6bcf\u4e2a\u7ec4\u4ef6\u7684 <code>name<\/code>\uff0c\u800c\u4e0d\u9700\u8981\u8bb0\u4f4f\u4ed6\u4eec\u5728 Vue Router \u4e2d\u5bf9\u5e94\u7684\u8def\u5f84\uff0c\u540c\u65f6\u65b9\u4fbf\u4e86\u5bf9\u8def\u5f84\u7684\u91cd\u65b0\u5b9a\u4e49\u3002<\/p>\n\n\n\n<p>\u7136\u800c\u6211\u611f\u89c9\u8fd8\u4e0d\u591f\uff0c\u56e0\u4e3a\u4ece\u67d0\u79cd\u610f\u4e49\u4e0a\u6765\u8bf4\uff0c\u8fd9\u4e0d\u8fc7\u662f\u5f15\u5165\u4e86\u4e00\u4e2a\u65b0\u7684 Magic String\uff08\u5373 <code>name<\/code> \u53d8\u91cf\uff09\u6765\u89e3\u51b3\u5176\u5b83 Magic String \u95ee\u9898\u7684\u62c6\u4e1c\u5899\u8865\u897f\u5899\u7684\u65b9\u6cd5\u3002<\/p>\n\n\n\n<p>\u5982\u679c\u8981\u9009\u62e9\u4ec0\u4e48\u5b57\u7b26\u4e32\u552f\u4e00\u5730\u4ee3\u8868\u4e00\u4e2a class\uff0c\u81ea\u7136\u662f class \u7684 <code>name<\/code> \u5c5e\u6027\u3002\u5728\u8fd9\u79cd\u60f3\u6cd5\u4e0b\uff0c\u6211\u7684 Vue Router \u4ee3\u7801\u5927\u6982\u53d8\u6210\u4e86\u8fd9\u4e2a\u6837\u5b50\uff1a<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">import SomeComponent from 'path\/to\/component.vue'\n\nconst routes: Array&lt;RouteConfig> = [\n  {\n    path: 'some-path',\n    name: SomeComponent.name,\n    component: SomeComponent\n  }\n  \/\/ ...\n]<\/pre>\n\n\n\n<p>\u4efb\u4f55\u5176\u4ed6\u7684\u4ee3\u7801\u4e2d\u82e5\u8981\u83b7\u53d6\u8fd9\u4e2a <code>name<\/code> \u4e4b\u9700\u8981 <code>import<\/code> \u8fd9\u4e2a\u7ec4\u4ef6\u7c7b\uff0c\u7136\u540e\u7528 <code>name<\/code> \u5c5e\u6027\u83b7\u53d6\u3002\u8fd9\u6837\u5904\u7406\u5f97\u8fd8\u7b97\u53ef\u4ee5\uff0c\u81f3\u5c11\u5728 develop \u73af\u5883\u4e0b\u6ca1\u6709\u51fa\u73b0\u8fc7\u95ee\u9898\u3002\u7136\u800c\u4e00\u65e6\u8fdb\u5165 production \u73af\u5883\uff0c\u95ee\u9898\u5c31\u66b4\u9732\u4e86\u51fa\u6765\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Minify \u5bfc\u81f4\u7684\u95ee\u9898<\/h2>\n\n\n\n<p>Vue \u7a0b\u5e8f\u8fd0\u884c <code>yarn run build<\/code> \u8fdb\u884c\u751f\u4ea7\u6253\u5305\u65f6\uff0cWebpack \u4f1a\u5c06\u4ee3\u7801 minify\uff0c\u8fd9\u8ba9\u4e0a\u8ff0\u7684\u89e3\u51b3\u65b9\u6848\u6210\u4e3a\u4e86\u5bfc\u81f4 bug \u7684\u6839\u6e90\u3002\u5728\u6211\u7684\u6d4b\u8bd5\u4e2d\uff0cbuild \u4e4b\u540e\u7684 Vue \u7a0b\u5e8f\u4e0d\u54cd\u5e94\u6307\u5b9a <code>name<\/code> \u7684\u8df3\u8f6c\u3002\u627e\u5230\u6302\u8f7d Vue App \u7684\u6807\u7b7e\uff0c\u67e5\u770b\u8def\u7531\uff0c\u7ed3\u679c\u53d1\u73b0\u4e24\u4e2a\u8def\u7531\u5bf9\u8c61\u7684 <code>name<\/code> \u5c5e\u6027\u7adf\u7136\u90fd\u662f <code>\"a\"<\/code>\u3002<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large\"><figure class=\"mdx-lazyload-container\" style=\"max-width:458px\"><div style=\"padding-top:134.06113537118%\"><\/div><div class=\"mdx-img-loading-sp mdui-valign\"><div><div class=\"mdui-spinner\"><\/div><\/div><\/div><img width=\"458\" height=\"614\" class=\"wp-image-774 lazyload\" title=\"Vue.js + TypeScript\uff1aclass style component \u6dfb\u52a0 static \u5c5e\u6027\" src=\"data:image\/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==\" data-src=\"https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-1.png\" alt=\"https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-1.png\" data-srcset=\"https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-1.png 458w, https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-1-224x300.png 224w\" sizes=\"(max-width: 458px) 100vw, 458px\"><\/figure><\/figure><\/div>\n\n\n\n<p>\u9605\u8bfb\u8c03\u8bd5 minify \u4e4b\u540e\u7684\u4ee3\u7801\uff0c\u53d1\u73b0 <code>export<\/code> \u7684 <code>name<\/code> \u7adf\u7136\u76f4\u63a5\u7528 <code>\"a\"<\/code> \u6307\u5b9a\u4e86\u3002<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large\"><figure class=\"mdx-lazyload-container\" style=\"max-width:1024px\"><div style=\"padding-top:30.6640625%\"><\/div><div class=\"mdx-img-loading-sp mdui-valign\"><div><div class=\"mdui-spinner\"><\/div><\/div><\/div><img width=\"1024\" height=\"314\" class=\"wp-image-775 lazyload\" title=\"Vue.js + TypeScript\uff1aclass style component \u6dfb\u52a0 static \u5c5e\u6027\" src=\"data:image\/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==\" data-src=\"https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-2-1024x314.png\" alt=\"https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-2-1024x314.png\" data-srcset=\"https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-2-1024x314.png 1024w, https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-2-300x92.png 300w, https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-2-768x235.png 768w, https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-2.png 1331w\" sizes=\"(max-width: 1024px) 100vw, 1024px\"><\/figure><\/figure><\/div>\n\n\n\n<p>\u81f3\u6b64\u53ef\u4ee5\u8ba4\u4e3a\u4efb\u4f55\u6d89\u53ca minify \u7684\u573a\u666f\uff0c\u51fd\u6570\u3001\u5bf9\u8c61\u3001\u7c7b\u7b49\u7b49\u7684 <code>name<\/code> \u5c5e\u6027\u4e0d\u5e94\u8be5\u53c2\u4e0e\u7a0b\u5e8f\u7684\u8fd0\u884c\u903b\u8f91\uff0c\u56e0\u4e3a\u6700\u5c0f\u5316\u540e\u7684\u4ee3\u7801\u867d\u7136\u4e0d\u6539\u53d8\u903b\u8f91\uff0c\u4f46\u6539\u53d8\u53d8\u91cf\u540d\uff0c\u800c\u4e14\u8fd8\u4f1a\u56e0\u4e3a JavaScript \u8bed\u8a00\u7248\u672c\u95ee\u9898\u5c06\u4e00\u79cd\u8bed\u6cd5\u6539\u53d8\u6210\u53e6\u4e00\u79cd\u8bed\u6cd5\uff08\u6bd4\u5982 ES6 \u7684 class \u6ca1\u6709\u51fa\u73b0\u5728 minify \u540e\u7684\u4ee3\u7801\u4e2d\uff09\u3002<\/p>\n\n\n\n<p>\u89e3\u51b3\u65b9\u6848\u4e4b\u4e00\u5f53\u7136\u662f build \u65f6\u5173\u95ed minify \u529f\u80fd\uff08\u89c1 <a href=\"https:\/\/github.com\/vuejs\/vue-cli\/issues\/4328#issuecomment-514250189\">https:\/\/github.com\/vuejs\/vue-cli\/issues\/4328#issuecomment-514250189<\/a>\uff09\u3002<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large\"><figure class=\"mdx-lazyload-container\" style=\"max-width:1024px\"><div style=\"padding-top:39.6484375%\"><\/div><div class=\"mdx-img-loading-sp mdui-valign\"><div><div class=\"mdui-spinner\"><\/div><\/div><\/div><img width=\"1024\" height=\"406\" class=\"wp-image-776 lazyload\" title=\"Vue.js + TypeScript\uff1aclass style component \u6dfb\u52a0 static \u5c5e\u6027\" src=\"data:image\/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==\" data-src=\"https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-3.png\" alt=\"https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-3.png\" data-srcset=\"https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-3.png 1024w, https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-3-300x119.png 300w, https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/image-3-768x305.png 768w\" sizes=\"(max-width: 1024px) 100vw, 1024px\"><\/figure><figcaption>name \u4e3a \u201cHome&#8221;\uff0c\u6ca1\u6709\u88ab\u6539\u53d8<\/figcaption><\/figure><\/div>\n\n\n\n<p>\u4f46 minify \u662f Web \u5f00\u53d1\u7684\u57fa\u672c\u9700\u6c42\uff0c\u56e0\u6b64\u7528 <code>class<\/code> \u7684 <code>name<\/code> \u4f5c\u4e3a <code>RouterConfig<\/code> \u7684 <code>name<\/code> \u662f\u8d70\u4e0d\u901a\u7684\u3002<\/p>\n\n\n\n<p>\u53e6\u4e00\u79cd\u89e3\u51b3\u65b9\u6848\u4e5f\u5f88\u663e\u7136\u4e86\uff0c\u5c31\u662f\u624b\u52a8\u6307\u5b9a\u67d0\u4e00\u5b57\u7b26\u4e32\uff0c\u7ed5\u5f00 minify \u7684\u5f71\u54cd\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u6700\u7ec8\u65b9\u6848<\/h2>\n\n\n\n<p>\u5bf9\u6bcf\u4e2a <code>RouterConfig<\/code> \u4e2d\u7684 <code>Component<\/code> \u7684 <code>class<\/code>\uff0c\u58f0\u660e\u65f6\u589e\u52a0\u4e00\u4e2a\u5c5e\u6027\uff0c\u5982\uff1a<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">@Component\nexport default class Home extends Vue {\n  static readonly id = 'Home'\n  \/\/ ...\n}<\/pre>\n\n\n\n<p>\u4f46\u8fd9\u4e2a\u65b9\u6848\u5e76\u4e0d\u662f\u5230\u8fd9\u91cc\u4e3a\u6b62\u8fd9\u4e48\u7b80\u5355\u3002\u76f4\u63a5\u5728 <code>RouterConfig<\/code> \u4e2d\u4f7f\u7528\u65f6 TypeScript \u4f1a\u6709\u5982\u4e0b\u62a5\u9519\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Property 'id' does not exist on type 'VueConstructor&lt;Vue&gt;'<\/code><\/pre>\n\n\n\n<p>\u539f\u56e0\u662f <code>*.vue<\/code> \u6587\u4ef6\u5e76\u4e0d\u76f4\u63a5\u80fd\u88ab TypeScript \u8bc6\u522b\u3002<code>import<\/code> Vue \u7ec4\u4ef6\u65f6\uff0c<code>tsc<\/code> \u5bf9\u8be5\u6587\u4ef6\u7c7b\u578b\u7684\u8bc6\u522b\u501f\u52a9 <code>src\/shims-vue.d.ts<\/code> \u6587\u4ef6\u3002\u6587\u4ef6\u9ed8\u8ba4\u7684\u5185\u5bb9\u4e3a\uff1a<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">declare module '*.vue' {\n  import Vue from 'vue'\n  export default Vue\n}<\/pre>\n\n\n\n<p>TypeScript \u7684 <code>.d.ts<\/code> \u6587\u4ef6\u7528\u4e8e\u5bf9\u975e TypeScript \u4ee3\u7801\u63cf\u8ff0\u7c7b\u578b\u3002\u4e0a\u8ff0\u4ee3\u7801\u63cf\u8ff0\u7684\u610f\u601d\u5373\uff0c\u6240\u6709\u4ee5 <code>.vue<\/code> \u7ed3\u5c3e\u7684\u6587\u4ef6\u90fd <code>export default<\/code> \u4e00\u4e2a\u7c7b\u578b\u4e0e &#8216;vue&#8217; \u4e2d\u7684 <code>Vue<\/code> \u76f8\u540c\u7684\u5bf9\u8c61\uff08\u5373 <code>VueConstructor&lt;Vue><\/code>\uff09\u3002\u663e\u7136\u8981\u8ba9 TypeScript \u77e5\u9053\u8ffd\u52a0\u7684 id \u7684\u8bdd\uff0c\u5c31\u8981\u5bf9\u8fd9\u4e2a\u6587\u4ef6\u4e0b\u624b\u4e86\u3002<\/p>\n\n\n\n<p>\u6211\u9b54\u6539\u540e\u7684 <code>vue.d.ts<\/code> \u6587\u4ef6\u5185\u5bb9\u5982\u4e0b\uff1a<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"typescript\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">declare module '*.vue' {\n  import Vue from 'vue'\n  export default class ComponentWithId extends Vue {\n    static readonly id: string\n  }\n}<\/pre>\n\n\n\n<p>\u5176\u5b9e\u5c31\u662f\u76f4\u63a5\u63cf\u8ff0\u4e86\u7528 class style component \u7684 <code>.vue<\/code> \u6587\u4ef6\u7684\u7ed3\u6784\u3002<\/p>\n\n\n\n<p>\u81f3\u6b64\u539f\u95ee\u9898\u548c TypeScript \u7684\u7c7b\u578b\u95ee\u9898\u4fbf\u90fd\u5f97\u5230\u89e3\u51b3\u4e86\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Vue Router \u7684 Magic String VueRouter \u7c7b\u7684\u6784\u9020\u51fd\u6570\u63a5\u53d7\u4e00\u4e2a\u5305\u542b routes: Array&lt;RouterConfig&gt; \u5c5e\u6027\u7684\u5bf9\u8c61\u4f5c\u4e3a\u53c2\u6570\uff0c\u4e00\u822c\u6765\u8bf4 routes \u8fd9\u6837\u5b9a\u4e49\uff1a \u5728\u4f7f\u7528 Vue Router \u65f6\uff0c\u5982\u679c\u8981\u8df3\u8f6c\u5230\u67d0\u4e2a\u754c\u9762\uff0c\u76f4\u63a5\u5c06 &lt;router-link&gt; \u6807\u7b7e\u7684 to attribute \u7ed1\u5b9a\u5230 { name: &#8216;SomeComponentName&#8217; }\uff0c\u6216\u5728\u7ec4\u4ef6\u7684\u65b9\u6cd5\u4e2d this.$router.push({ name: &#8216;SomeComponentName&#8217; }) \u5373\u53ef\u3002\u8fd9\u6837\u5904\u7406\u53ea\u9700\u8981\u6bcf\u4e2a\u7ec4\u4ef6\u7684 name\uff0c\u800c\u4e0d\u9700\u8981\u8bb0\u4f4f\u4ed6\u4eec\u5728 Vue Router \u4e2d\u5bf9\u5e94\u7684\u8def\u5f84\uff0c\u540c\u65f6\u65b9\u4fbf\u4e86\u5bf9\u8def\u5f84\u7684\u91cd\u65b0\u5b9a\u4e49\u3002 \u7136\u800c\u6211\u611f\u89c9\u8fd8\u4e0d\u591f\uff0c\u56e0\u4e3a\u4ece\u67d0\u79cd\u610f\u4e49\u4e0a\u6765\u8bf4\uff0c\u8fd9\u4e0d\u8fc7\u662f\u5f15\u5165\u4e86\u4e00\u4e2a\u65b0\u7684 Magic String\uff08\u5373 name \u53d8\u91cf\uff09\u6765\u89e3\u51b3\u5176\u5b83 Magic String \u95ee\u9898\u7684\u62c6\u4e1c\u5899\u8865\u897f\u5899\u7684\u65b9\u6cd5\u3002 \u5982\u679c\u8981\u9009\u62e9\u4ec0\u4e48\u5b57\u7b26\u4e32\u552f\u4e00\u5730\u4ee3\u8868\u4e00\u4e2a class\uff0c\u81ea\u7136\u662f class \u7684 name \u5c5e\u6027\u3002\u5728\u8fd9\u79cd\u60f3\u6cd5\u4e0b\uff0c\u6211\u7684 Vue Router \u4ee3\u7801\u5927\u6982\u53d8\u6210\u4e86\u8fd9\u4e2a\u6837\u5b50\uff1a \u4efb\u4f55\u5176\u4ed6\u7684\u4ee3\u7801\u4e2d\u82e5\u8981\u83b7\u53d6\u8fd9\u4e2a name \u4e4b\u9700\u8981 import [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":779,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","enabled":false},"version":2}},"categories":[29,17],"tags":[30,31,32,33],"class_list":["post-769","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-develop","category-recommendation","tag-30","tag-31","tag-vue","tag-typescript"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/www.eolstudy.com\/wp-content\/uploads\/2021\/06\/vue-ts.png","jetpack_sharing_enabled":true,"jetpack_likes_enabled":true,"_links":{"self":[{"href":"https:\/\/www.eolstudy.com\/index.php\/wp-json\/wp\/v2\/posts\/769"}],"collection":[{"href":"https:\/\/www.eolstudy.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.eolstudy.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.eolstudy.com\/index.php\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.eolstudy.com\/index.php\/wp-json\/wp\/v2\/comments?post=769"}],"version-history":[{"count":8,"href":"https:\/\/www.eolstudy.com\/index.php\/wp-json\/wp\/v2\/posts\/769\/revisions"}],"predecessor-version":[{"id":785,"href":"https:\/\/www.eolstudy.com\/index.php\/wp-json\/wp\/v2\/posts\/769\/revisions\/785"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.eolstudy.com\/index.php\/wp-json\/wp\/v2\/media\/779"}],"wp:attachment":[{"href":"https:\/\/www.eolstudy.com\/index.php\/wp-json\/wp\/v2\/media?parent=769"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.eolstudy.com\/index.php\/wp-json\/wp\/v2\/categories?post=769"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.eolstudy.com\/index.php\/wp-json\/wp\/v2\/tags?post=769"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}