'', 'production' => false, 'siteName' => 'David T. Sadler', 'siteDescription' => 'My little bit of the Internet', 'siteAuthor' => 'David T. Sadler', 'perPage' => 2, // Collections 'collections' => [ 'posts' => [ // Default author, if not provided in a post 'author' => 'David T. Sadler', 'sort' => '-date', 'path' => '/{filename}', ], 'categories' => [ 'path' => '/categories/{filename}', 'posts' => function ($page, $allPosts) { return $allPosts->filter(function ($post) use ($page) { return $post->categories ? in_array($page->getFilename(), $post->categories, true) : false; }); }, ], ], // Helpers 'getDate' => function ($page) { return Datetime::createFromFormat('U', $page->date); }, 'allCategories' => function ($page, $allPosts) { return $allPosts->pluck('categories')->flatten()->unique(); }, ];