Saleor Core: the high performance, composable, headless commerce API.
Python cartcheckoutcommercecomposablee-commerceecommercegraphqlheadlessheadless-commercemultichannelomsorder-managementpaymentspimpythonshopshopping-cartstore
Get rid of <Shop /> component
dominik-zeglen598e25bf891d
diff --git a/saleor/static/dashboard-next/components/WindowTitle/index.tsx b/saleor/static/dashboard-next/components/WindowTitle/index.tsxindex c1b54adf97..2138ce6bb6 100644--- a/saleor/static/dashboard-next/components/WindowTitle/index.tsx+++ b/saleor/static/dashboard-next/components/WindowTitle/index.tsx@@ -1,7 +1,7 @@import * as React from "react";import { Helmet } from "react-helmet";-import Shop from "../Shop";+import useShop from "../../hooks/useShop";interface WindowTitleProps {title: string;@@ -9,14 +9,12 @@ interface WindowTitleProps {export const WindowTitle: React.StatelessComponent<WindowTitleProps> = ({title-}) => (- <Shop>- {shop =>- shop === undefined || !title ? null : (- <Helmet>- <title>{`${title} | ${shop.name}`}</title>- </Helmet>- )- }- </Shop>-);+}) => {+ const shop = useShop();++ return shop === undefined || !title ? null : (+ <Helmet>+ <title>{`${title} | ${shop.name}`}</title>+ </Helmet>+ );+};