Skip to content

[web] blog list#271

Open
DagmawitG wants to merge 8 commits intomainfrom
dagmawit.demo-project
Open

[web] blog list#271
DagmawitG wants to merge 8 commits intomainfrom
dagmawit.demo-project

Conversation

@DagmawitG
Copy link

No description provided.

@vercel
Copy link

vercel bot commented Aug 2, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
practice ❌ Failed (Inspect) Sep 2, 2022 at 0:29AM (UTC)
practice-project-vue ❌ Failed (Inspect) Sep 2, 2022 at 0:29AM (UTC)
practice-vue ❌ Failed (Inspect) Sep 2, 2022 at 0:29AM (UTC)

</v-card-title>

<v-card-subtitle>{{ blogPost.content }}</v-card-subtitle>
<nuxt-link :to="'/dagmawit/' + blogPost._id">
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:to="/dagmawit${blogPost._id}"

Comment on lines +33 to +35
<!-- <v-card-actions>
<v-btn text :to="'/dagmawit/' + blog._id"> Read More </v-btn>
</v-card-actions> -->
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove this

@@ -0,0 +1,43 @@
<template>
<div>
<nuxt-link :to="'/dagmawit/'">
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

to="dagmawit"

</template>

<script>
import axios from 'axios'
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no need to import axios. you can access it using this.$axios

this.blogTitle = response.data.title
this.blogContent = response.data.content
} catch (err) {
console.log(err)
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit; no-console

)
this.blog = this.response.data
} catch (err) {
this.$nuxt.error({
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This page crashes when it loads. it isn't fetching the blog ig

and better copy the method to a store actions and call it like this.$store.dispatch('dagmawit/fetchblogDetail', id) etc
also use this.$axios for requests too

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants