-
Notifications
You must be signed in to change notification settings - Fork 1
Create Serverless CMS Cookbook for Vue V3 #1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create Serverless CMS Cookbook for Vue V3 #1
Conversation
@orlyohreally Images are broken in the .md file: https://github.com/ButterCMS/docs/blob/ae8471f8d47b7c3937abec66144349094b8920d5/src/cookbook/serverless-blog.md Let's make sure they are up to date images as well in terms of our new blog post editor UI. Can grab pictures from: https://buttercms.com/features/ if needed |
ae8471f
to
f4049e7
Compare
I have replaced the image with post editor UI with the one from the features page. I have checked and it seems that other recipes also have images not displaying when viewing .md files, but they work when you run the project |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added some recommendations for stylistic updates.
Looks good otherwise!
src/cookbook/serverless-blog.md
Outdated
</template> | ||
|
||
<script> | ||
import { butter } from "@/buttercms" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lets move this down below import { RouterLink }
as we are third-party and want to ensure that Vue is the prime import.
src/cookbook/serverless-blog.md
Outdated
import { defineComponent, onMounted, ref, unref } from "vue" | ||
import { RouterLink, useRoute } from "vue-router" | ||
|
||
import { butter } from "@/buttercms.js" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets be consistent here and ensure this is import { butter } from "@/buttercms"
src/cookbook/serverless-blog.md
Outdated
import { defineComponent, onMounted, ref, unref, watch } from "vue" | ||
import { RouterLink, useRoute } from "vue-router" | ||
|
||
import { butter } from "@/buttercms.js" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets be consistent here and ensure this is import { butter } from "@/buttercms"
src/cookbook/serverless-blog.md
Outdated
const categories = await getCategories() | ||
const postsByCategory = await getPostsByCategory( "example-category" ) | ||
|
||
console.log(categories, postsByCategory) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets remove the console.log
unless we are describing why thats in the code. if it should remain, then lets do:
console.log({ categories, postsByCategory })
which will output:
{
categories: [ ... ],
postsByCategory: [ ... ]
}
this is easier in the console to tell what data you are looking at.
f4049e7
to
97b93ad
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good from here.
Awesome thanks @courcelan |
A cookbook recipe on how to quickly build a CMS-powered blog with Vue.js and ButterCMS