Make Slate client-side only

This commit is contained in:
Kristian Polso 2018-06-25 09:10:15 +03:00
parent 729f2eecb1
commit 543b9102ad
2 changed files with 7 additions and 4 deletions

View file

@ -53,7 +53,8 @@
htmlContent: "", htmlContent: "",
searchIndex: {}, searchIndex: {},
searchResults: {}, searchResults: {},
toc: {} toc: {},
markdownFile: ""
} }
}, },
@ -154,8 +155,8 @@
} }
}, },
mounted: function () { created: function () {
this.$http.get("/api.md").then(function (response) { this.$http.get(this.markdownFile).then(function (response) {
this.htmlContent = md.render(response.body); this.htmlContent = md.render(response.body);
this.$nextTick(function () { this.$nextTick(function () {

View file

@ -1 +1,3 @@
<!--/ < Slate markdown-file="/api.md" /> /--> <ClientOnly>
<Slate markdown-file="/api.md"></Slate>
</ClientOnly>