does angular material have a grid system?

前端 未结 3 1005
忘掉有多难
忘掉有多难 2021-02-04 01:28

I\'m starting a project with angular material. Does it have a native system for positioning elements in a responive grid like bootstrap does ?

Otherwise is it ok practic

3条回答
  •  滥情空心
    2021-02-04 01:53

    If you are using Material2, you can use Angular Flex Layout for responsiveness. It compliments Angular2 well and is lightweight.

    Basically Material2 + Flex-layout is equivalent to Bootsrap library.

    Here's an example of how flex-layout can be used for grid system/responsiveness with Angular/Material2.

    Sample Code showing use of flex-layout API:

    Screen size

    XS

    Screen size

    SM

    Screen size

    MD

    Screen size

    LG

    Screen size

    XL

    Div 1
    Div 2
    Div 3
    Div 4
    Div 5
    Div 6
    Div 7
    Div 8

提交回复
热议问题