laravel/laravel — Issue #247: Eager loading for multiple levels in Eloquent [Feature Request]
Author: sqwk
Created: 2012-01-19 14:22:13+00:00
State: open

At the moment Eloquent supports eager loading like so:

$post = Post::with('category', 'comments')->get();

However, it is not possible to eager load multiple levels . A proposed syntax would be:

$posts = Post::with('category', 'comments' => array('author'))->get()