Using flexbox with angular 2 components

前端 未结 3 777
长情又很酷
长情又很酷 2021-02-05 10:49

I want to update visual side(grid, colors) of my angular 2 application. Old layout was build with bootstrap 4, which I don\'t really need anymore. I decided to go for plain css3

3条回答
  •  挽巷
    挽巷 (楼主)
    2021-02-05 11:30

    :host selector solves the problem but you end using it very often in many components.

    I used instead the following global CSS:

    .row > * {
      display: flex;
      flex-basis: 100%;
    }
    

提交回复
热议问题