DEV Community

Discussion on: What are you learning this week? And why???

Collapse
 
ekeijl profile image
Edwin • Edited

Figuring out how to nicely print only a specific section of a webpage, without breaking the markup or styling. Was playing with some HTML-to-PDF libraries, but they are all equally terrible in both the end result and documentation. Then I figured I could just use the @media print CSS rules to create a print preview screen. Then the user can just hit CTRL+P and only print the part that they want. Super easy! πŸŽ‰

  • oh and why? Just for work! :)
Collapse
 
pachicodes profile image
Pachi πŸ₯‘

That is great! I love how useful CSS is! And Soo underrated