Skip to content

Get boolean for screen size #2221

Answered by ljosberinn
ivanjeremic asked this question in Q&A
Oct 12, 2020 · 2 comments · 11 replies
Discussion options

You must be logged in to vote

https://next.chakra-ui.com/docs/hooks/use-breakpoint-value#usage

const breakpoint = useBreakpointValue({ base: "base", sm: "sm", lg: "lg", xl: "xl" })

const isBase = breakpoint === 'sm';
// etc

Replies: 2 comments 11 replies

Comment options

You must be logged in to vote
7 replies
@ljosberinn
Comment options

@ivanjeremic
Comment options

@ljosberinn
Comment options

@ivanjeremic
Comment options

@ljosberinn
Comment options

Answer selected by ivanjeremic
Comment options

You must be logged in to vote
4 replies
@ljosberinn
Comment options

@ivanjeremic
Comment options

@ivanjeremic
Comment options

@ljosberinn
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants