This change makes sure the seo plugin uses the correct locale when analysing content.
Breaking change
You now need to provide the seo view with some options:
import multiLanguageConfig from 'config:@kaliber/sanity-plugin-multi-language'
import { SeoAnalysis, typeHasSeo } from '@kaliber/sanity-plugin-seo'
export function getDefaultDocumentNode({ schemaType }) {
return S.document().views([
S.view.form(),
...(typeHasSeo(schemaType) ? [S.view.component(SeoAnalysis).options({ multiLanguage: multiLanguageConfig }).title('SEO')] : []),
])
}
(refer to @kaliber/sanity-plugin-multi-language@2
's config.dist.json
if you're wondering what shape the multiLanguageConfig
should have)