Closed hachi1030-Allen closed 5 years ago
@hachi1030-Allen SEO is a broad topic and Minos is not specially optimized for SEO. However, many SEO approaches used in other sites/themes are generic and can be applied to Minos as well. You can modify the layout files directly for this.
@ppoffice
Hi there, thanks for the reply.
I only have one question here, please check the below screen that from SEO document for NEXT theme:
It's trying to modify the title format for each document for SEO purpose. But I cannot find the similar code block in Minos theme. Can you show me how to apply this to your theme?
Thanks,
Allen
@ppoffice
Thanks for the reply.
I have 2 questions about this:
In the above screenshot that I shared with you, since it's the Next theme, so it's based on Swig file language format. Eg: {{ config.title }}{{ theme.description }}
But in our theme, we are based on ejs, so your code will look like: <title><%= page_title() %></title>
, may I know how can I modify to the same format which should indicates the title like "title - description", what's the calling function for the same as theme.description
as the above code showed?
I added the Keywords in the theme's _config.yml, such as below:
But looks like it will not show up in the page's header with a meta tag named as keywords. May I know why this is happening?
BTW, I also said hi to you on Wechat, it will be better if you can reply that so that we can move this faster.
Thanks,
Allen
@hachi1030-Allen Description is here: https://github.com/ppoffice/hexo-theme-minos/blob/master/layout/common/head.ejs#L8 You just have to move it up to the title tag:
<title><%= page_title() %><%- get_config('description') %></title>
The keywords should be
keywords: Xamarin, Allen, Microsoft, Technical, .Net
And if you use different keywords for different post, you better add that to the post's front-matter.
@ppoffice
Cool. Thanks for the great information.
BTW, <title><%= page_title() %><%- get_config('description') %></title>
, I saw you put the '-' before get_config('description'), should it be '=' as the page_title() or not?
Anyway I will try your solution tonight and get back to you.
Thanks a lot!
Allen
Hi there,
according to search results online, most of the SEO documents are about the NEXT theme.
May I know how to do SEO in your blog theme?
Thanks!
Allen