@heseya/store-core
Advanced tools
Comparing version 2.1.0-rc.1 to 2.1.0-rc.2
{ | ||
"name": "@heseya/store-core", | ||
"version": "2.1.0-rc.1", | ||
"version": "2.1.0-rc.2", | ||
"author": { | ||
@@ -5,0 +5,0 @@ "name": "Heseya" |
@@ -11,3 +11,11 @@ import { isNil } from 'lodash' | ||
const get = (key: keyof SeoMetadata) => { | ||
return seoMetadatas.find((s) => !isNil(s[key]))?.[key] | ||
return seoMetadatas.find((s) => { | ||
if (!s) return false | ||
const value = s[key] | ||
if (key === 'og_image' || key === 'no_index') return !isNil(value) | ||
if (key === 'description' || key === 'title' || key === 'twitter_card') | ||
return (value as string)?.length > 0 | ||
if (key === 'keywords') return (value as string[])?.length > 0 | ||
})?.[key] | ||
} | ||
@@ -14,0 +22,0 @@ |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
3481064
59
28235