artiebits / svelte-seo

Optimize your website for search engines and social media with meta tags, Open Graph, and JSON-LD.
https://artiebits.com
MIT License
446 stars 24 forks source link

Minimun required Fields from Backend? #43

Closed Rar9 closed 1 year ago

Rar9 commented 2 years ago

What minimum BACKEND fields apart Title/Description are required, to fully utilize this Svelte-SEO addon and stay flexible?

lubiah commented 2 years ago

Hello @Rar9, those are the only required ones though the rest helps to boost your SEO, they are not compulsory

Rar9 commented 2 years ago

This is not clear.

So in a backend I just need title/description /image

What other fields are required to use alll options to this module?

lubiah commented 2 years ago

I do not understand why you keep referencing backend, is the title and description for your page pulled from a database

Rar9 commented 2 years ago

I like to keep data all seo data in backend to stay flexible.

So if i only have the default title /description I'll limit my seo as twitter cards / opengraph.... Will have further possibilities.

This starts with possible of max characters used to other advantage seo fields.

lubiah commented 2 years ago

You can use the default title and description to fill in the props for Twitter cards.

For example, let's say you have a title and description in js.

<script>
  const SEO = {
    title: "My title",
    description: "My description"
};
</script>

<SvelteSeo
 title = {SEO.title}
description= {SEO.description}

openGraph = {{
 title: SEO.title,
description: SEO.description
}}

/>

You can use this method to use only the title and description to fill in the props for both twitter cards and Opengraph

Rar9 commented 2 years ago

Yes, I can clone then 2x, but articles /products in opengraph have more variations.

To be able the stay flexible in backend I will need further fieldsx so the user can easily edit these

lubiah commented 2 years ago

Then you need to adjust your database to store these values

Rar9 commented 2 years ago

Yes, but I'm looking for minimal set of fields to stay as flexibleas possible.

Stuff like seo generator can move to frontend like sveltekit

Robots like follow /no follow need to be put in the backend