Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[mantine.dev] update use-favicon hook example to use cookieless domain #7303

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -10,31 +10,31 @@ import { Group, Button } from '@mantine/core';

function Demo() {
const [favicon, setFavicon] = useState('https://mantine.dev/favicon.svg');
const setXFavicon = () => setFavicon('https://x.com/favicon.ico');
const setMantineFavicon = () => setFavicon('https://mantine.dev/favicon.svg');
const setMantineUIFavicon = () => setFavicon('https://ui.mantine.dev/favicon.svg');

useFavicon(favicon);

return (
<Group justify="center">
<Button onClick={setXFavicon}>X favicon</Button>
<Button onClick={setMantineFavicon}>Mantine favicon</Button>
<Button onClick={setMantineUIFavicon}>Mantine UI favicon</Button>
</Group>
);
}
`;

function Demo() {
const [favicon, setFavicon] = useState('https://mantine.dev/favicon.svg');
const setXFavicon = () => setFavicon('https://x.com/favicon.ico');
const setMantineFavicon = () => setFavicon('https://mantine.dev/favicon.svg');
const setMantineUIFavicon = () => setFavicon('https://ui.mantine.dev/favicon.svg');

useFavicon(favicon);

return (
<Group justify="center">
<Button onClick={setXFavicon}>X favicon</Button>
<Button onClick={setMantineFavicon}>Mantine favicon</Button>
<Button onClick={setMantineUIFavicon}>Mantine UI favicon</Button>
</Group>
);
}
Expand Down
Loading