Call remote from Post component

This commit is contained in:
Raymonzut
2020-04-25 16:39:56 +02:00
parent 3b22f15a45
commit 8cdc2f8767
+13
View File
@@ -8,8 +8,21 @@
</template>
<script>
import { getPosts } from '../remote'
export default {
name: "Post",
data() {
return {
post: {},
}
},
methods: {
getPosts
},
mounted() {
getPosts.call(this, this._props.id)
},
props: {
id: {
type: String,