The U.S. Constitution prevents the government from performing searches without a valid reason; the government generally can't snoop through your laptop for no reason. Electronic data stored on personal devices is a reflection of our lives - family photos, medical documents, banking information, details about what websites we visit, and so much more. But those privacy protections don't safeguard travelers at the U.S. border, where the U.S. government can take an electronic device, search through all the files, and keep it for a while for further scrutiny – without any suspicion of wrongdoing whatsoever.
A guide worth reading if you're a frequent traveler is called - Defending Privacy at the U.S. Border: A Guide for Travelers Carrying Digital Devices.
Read the guide by Seth Schoen, Marcia Hofmann and Rowan Reynolds here - https://www.eff.org/sites/default/files/EFF-border-search_2.pdf