Laravel how to get last week posts?

Edward Ziadeh • 14 March 2019
Blog in group Laravel
0 comments
0 likes
$date = \Carbon\Carbon::today()->subDays(7);

$posts = Post::where('created_at', '>=', $date)->get();

dd($posts);