Skip to content

Commit

Permalink
chore: improve seo tags
Browse files Browse the repository at this point in the history
  • Loading branch information
icfor committed Nov 22, 2023
1 parent 6819e07 commit 5c55959
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 15 deletions.
4 changes: 2 additions & 2 deletions next-sitemap.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ module.exports = {
priority: null,

generateRobotsTxt: false,
siteUrl: "https://forbole.com",
siteUrl: "https://www.forbole.com",
additionalPaths: async () => {
if (!process.env.GHOST_PRIVATE_KEY || !process.env.NEXT_PUBLIC_GHOST_API)
return [];
Expand Down Expand Up @@ -38,7 +38,7 @@ module.exports = {
return posts
.map((p) => {
if (!p.slug) return null;
if (p.slug.includes("page/")) return null;
if (p.slug.statrtsWith("how-to-stake")) return `/staking/${p.slug}`;

return `/blog/${p.slug}`;
})
Expand Down
27 changes: 15 additions & 12 deletions src/components/layout_val/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,29 +11,31 @@ import GuideNav from "../guide_nav";
import Nav from "../nav";

type Props = {
canonical?: string;
children?: ReactNode;
title?: string;
footer?: boolean;
description?: string;
keywords?: string[];
type?: string;
footer?: boolean;
image?: string;
twitterImage?: string;
stakingGuide?: boolean;
keywords?: string[];
stakeNowRef?: RefObject<HTMLElement>;
stakingGuide?: boolean;
title?: string;
twitterImage?: string;
type?: string;
};

const LayoutVal = ({
canonical,
children,
title = "Forbole",
footer,
description,
keywords = [],
type = "website",
footer,
image,
twitterImage,
stakingGuide,
keywords = [],
stakeNowRef,
stakingGuide,
title = "Forbole",
twitterImage,
type = "website",
}: Props) => {
const theme = useTheme();
const router = useRouter();
Expand Down Expand Up @@ -111,6 +113,7 @@ const LayoutVal = ({
type="image/png"
/>
<link href={`${url}/icons/manifest.json`} rel="manifest" />
{canonical && <link href={canonical} rel="canonical" />}
</Head>
<Box
sx={{
Expand Down
1 change: 1 addition & 0 deletions src/screens/network_guides/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ const NetworkGuides = ({ post }: any) => {

return (
<LayoutVal
canonical={`https://www.forbole.com/staking/${post.slug}`}
description={post.excerpt}
footer
image={post.featureImage}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,11 @@ const NetworkCard: FC<CardProp> = (props: CardProp) => {
</Box>
<Button
className="networkbox__mobile-anchor"
onClick={handleMobileAnchorClick}
onClick={
isEmptyPopover && canClickNetwork
? handleExploreClick
: handleMobileAnchorClick
}
variant="text"
>
{networkImage}
Expand Down

0 comments on commit 5c55959

Please sign in to comment.