breakpoints 0.2.0

Dart native js
Flutter Android iOS web

A simple library for getting page breakpoints xs, sm, md, lg, xl

breakpoints #

A simple library for getting page breakpoints xs, sm, md, lg, xl

Inspired by material-ui

breakpoints:

xs: 0
sm: 600
md: 960
lg: 1280
xl: 1920
innerWidth  |xs      sm       md       lg       xl
            |--------|--------|--------|--------|-------->
width       |   xs   |   sm   |   md   |   lg   |   xl

Install #

dependencies:
  breakpoints:

Usage #

double width = MediaQuery.of(context).size.width;

Breakpoints.only(width, [Breakpoints.xs, Breakpoints.lg])
    ? Text('xs or lg')
    : Container()

Breakpoints.isSm(width) ? Text('isSm') : Container()

width.isXl ? Text('isXl') : SizedBox()

Breakpoints(200).toString() // xs
0
likes
110
pub points
40%
popularity

A simple library for getting page breakpoints xs, sm, md, lg, xl

Repository (GitHub)
View/report issues

Documentation

API reference

Uploader

ajanuw1995@gmail.com

License

unknown (LICENSE)

More

Packages that depend on breakpoints