-
-
Notifications
You must be signed in to change notification settings - Fork 853
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
Improved seo docs page #297
base: main
Are you sure you want to change the base?
Conversation
Added Other Pages Meta Tags & Structured data and Schema markup
Added Other Pages Meta Tags & Structured data and Schema markup
Update seo.md
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.
Awesome work @NeroxTGC , thanks for this!
I think this generaly makes sense and looks good -> I left some comments, but nothing major I believe, let's take care of those and we can merge!
:::note[Important] | ||
By default, all pages will acquire the main Landing Page meta tags. You can set custom meta tags for each page using `react-helmet-async`. | ||
::: |
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.
I think we can probably just take this out of :::note, make it normal text. I understand it was meant to emphasize it as the most important thing here, which it is, but it actually fits well into the normal flow of the reading while :::notes break it a bit.
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.
@NeroxTGC what happened to this part, you removed it? I thought it was a quite good intro and explanation, seems shame to not have it! What I was suggesting was just to not have it as a "note", but as a normal parapgrah.
## Structured data and Schema markup | ||
|
||
:::note[Tip] | ||
Crawlers do all the work of analyzing and understanding the content of your pages, and they will thank you if you include structured data to help them understand what your content is about!🤗. | ||
::: | ||
|
||
You can add structured data for each page. | ||
|
||
```jsx {14-22} | ||
//... | ||
import { Helmet, HelmetProvider } from 'react-helmet-async'; | ||
|
||
export function MyCustomPage() { | ||
return ( | ||
<div> | ||
<Helmet> | ||
<title>My Custom Page Title</title> | ||
<meta | ||
name='description' | ||
content='This is the meta description of my page.'/> | ||
<link rel='canonical' href='https://example.com/my-custom-page' /> | ||
//... | ||
|
||
<script type='application/ld+json'>{` | ||
{ | ||
"@context": "https://schema.org", | ||
"@type": "SoftwareApplication", | ||
"name": "title", | ||
"url": "https://yoururl.com", | ||
"description": "Description", | ||
} | ||
} | ||
`} </script> | ||
|
||
</Helmet> | ||
//... | ||
``` | ||
|
||
|
||
These resources provide the information needed to get the most out of structured data: | ||
- [Introduction to structured data markup](https://developers.google.com/search/docs/appearance/structured-data/intro-structured-data) | ||
- [General structured data guidelines](https://developers.google.com/search/docs/appearance/structured-data/sd-policies) | ||
|
||
After you have a small notion about them, you can go deeper by adding custom functions depending on your app (FAQs, Rating, Review, Software Application...): | ||
- [ALL structured data functions](https://developers.google.com/search/docs/appearance/structured-data/search-gallery) | ||
|
||
To ensure that they are valid: | ||
- [Google rich results test](https://search.google.com/test/rich-results) | ||
- [Schema validator](https://validator.schema.org/) |
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.
This dive intro structured data might and schema markup might be a bit beyond the scope of this docs. That said, we can provide a sentence or two about it + a single link, or max two, where they can read about them. Meaning we can significantly shorten this part and throw out the code example!
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.
@NeroxTGC ping on this - what do you think?
@Martinsos I finished updating the document with your suggested changes. If you like, check it one last time. I've also created a |
export default function App() { | ||
return ( | ||
<HelmetProvider> | ||
<> |
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.
@NeroxTGC what about this one?
|
||
```jsx {14-22} | ||
//... | ||
import { Helmet, HelmetProvider } from 'react-helmet-async'; |
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.
redundant import of helmet provider
## Structured data and Schema markup | ||
|
||
:::note[Tip] | ||
Crawlers do all the work of analyzing and understanding the content of your pages, and they will thank you if you include structured data to help them understand what your content is about!🤗. | ||
::: | ||
|
||
You can add structured data for each page. | ||
|
||
```jsx {14-22} | ||
//... | ||
import { Helmet, HelmetProvider } from 'react-helmet-async'; | ||
|
||
export function MyCustomPage() { | ||
return ( | ||
<div> | ||
<Helmet> | ||
<title>My Custom Page Title</title> | ||
<meta | ||
name='description' | ||
content='This is the meta description of my page.'/> | ||
<link rel='canonical' href='https://example.com/my-custom-page' /> | ||
//... | ||
|
||
<script type='application/ld+json'>{` | ||
{ | ||
"@context": "https://schema.org", | ||
"@type": "SoftwareApplication", | ||
"name": "title", | ||
"url": "https://yoururl.com", | ||
"description": "Description", | ||
} | ||
} | ||
`} </script> | ||
|
||
</Helmet> | ||
//... | ||
``` | ||
|
||
|
||
These resources provide the information needed to get the most out of structured data: | ||
- [Introduction to structured data markup](https://developers.google.com/search/docs/appearance/structured-data/intro-structured-data) | ||
- [General structured data guidelines](https://developers.google.com/search/docs/appearance/structured-data/sd-policies) | ||
|
||
After you have a small notion about them, you can go deeper by adding custom functions depending on your app (FAQs, Rating, Review, Software Application...): | ||
- [ALL structured data functions](https://developers.google.com/search/docs/appearance/structured-data/search-gallery) | ||
|
||
To ensure that they are valid: | ||
- [Google rich results test](https://search.google.com/test/rich-results) | ||
- [Schema validator](https://validator.schema.org/) |
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.
@NeroxTGC ping on this - what do you think?
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.
@NeroxTGC nice, there is still some stuff to fix though, I commented!
template/app/public/robots.txt
Outdated
Disallow: /api/ | ||
Disallow: /auth/ |
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.
hm so api and auth here - do we need that? because those are parts of the server, and server is not hosted at the same url as client, at least not usually.
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.
updated, you are right.
Co-authored-by: Martin Šošić <[email protected]>
Co-authored-by: Martin Šošić <[email protected]>
Seo Guide
OpenSaaS template
@Martinsos I don't think I've missed anything now, right? |
Description
Contributor Checklist