Skip to content

Commit

Permalink
added default title and lang attribute
Browse files Browse the repository at this point in the history
  • Loading branch information
remko48 committed Jan 29, 2024
1 parent 2d19a73 commit e0a3677
Show file tree
Hide file tree
Showing 6 changed files with 51 additions and 1 deletion.
5 changes: 5 additions & 0 deletions pwa/gatsby-browser.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,8 @@ export const wrapRootElement = ({ element }) => {
</QueryClientProvider>
);
};

export const onRenderBody = ({ setHeadComponents }) => {
const HeadComponents = [<title key={0}>Woo Website Template</title>];
setHeadComponents(HeadComponents);
};
6 changes: 6 additions & 0 deletions pwa/gatsby-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,5 +40,11 @@ module.exports = {
],
},
},
{
resolve: "gatsby-plugin-html-attributes",
options: {
lang: "nl-NL",
},
},
],
};
5 changes: 5 additions & 0 deletions pwa/gatsby-ssr.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,8 @@ export const wrapRootElement = ({ element }) => {
</QueryClientProvider>
);
};

export const onRenderBody = ({ setHeadComponents }) => {
const HeadComponents = [<title key={0}>Woo Website Template</title>];
setHeadComponents(HeadComponents);
};
30 changes: 30 additions & 0 deletions pwa/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion pwa/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
"private": true,
"description": "Product Website Template",
"author": "Conduction",
"keywords": ["gatsby"],
"keywords": [
"gatsby"
],
"scripts": {
"develop": "gatsby develop",
"start": "gatsby develop",
Expand Down Expand Up @@ -68,6 +70,7 @@
"dedent": "^1.5.1",
"gatsby": "^5.13.3",
"gatsby-plugin-breadcrumb": "^12.3.2",
"gatsby-plugin-html-attributes": "^1.0.5",
"gatsby-plugin-layout": "^4.13.1",
"html-react-parser": "^5.1.1",
"i18next": "^23.7.19",
Expand Down
1 change: 1 addition & 0 deletions pwa/src/layout/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import { far } from "@fortawesome/free-regular-svg-icons";
import { IconPack, library } from "@fortawesome/fontawesome-svg-core";
import { useEnvironment } from "../hooks/useEnvironment";
import { ToolTip } from "@conduction/components";
import { Helmet } from "react-helmet";

export const TOOLTIP_ID = "cb8f47c3-7151-4a46-954d-784a531b01e6";

Expand Down

0 comments on commit e0a3677

Please sign in to comment.