Skip to content

p-datatable-gridlines does not work together with bootstrap #2541

Answered by qwadrox
wima75 asked this question in PrimeNG
Discussion options

You must be logged in to vote
  • You need to create CSS layers for sure to separate the CSS that might interfere with PrimeNg: https://primeng.org/guides/csslayer#bootstrap

  • Here is an example how I did: https://stackblitz.com/edit/smmbf9-dhq1oc?file=src%2Fstyles.scss I put the whole bootstrap on a separate layer.

  • Because the main bootstrap file includes everything
    you don't need to separately import the bootstrap-reboot.css .

  • Or if you go to the direction what the docs say, then import all component separately that you're using:

    @layer bootstrap-reboot, primeng
    
    @layer bootstrap-reboot {
      @import 'bootstrap/scss/bootstrap-reboot';
    }
    
    @import 'bootstrap/scss/bootstrap-grid';
    @import 'bootstrap/scss/bootstrap-util…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@wima75
Comment options

Answer selected by wima75
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants