Exemplo n.º 1
0
 /**
  * Display a listing of posts.
  *
  * @return \Illuminate\Http\Response
  */
 public function index()
 {
     $posts = Post::getLatest(10);
     return view('flashtag::posts.index', compact('posts'));
 }
Exemplo n.º 2
0
 /**
  * Display the default page.
  *
  * @return \Illuminate\Http\Response
  */
 public function index()
 {
     $posts = Post::getLatest(10);
     $categories = Category::all();
     return view('flashtag::home', compact('posts', 'categories'));
 }