axkuhta 1 рік тому
батько
коміт
cbb3099ba2

+ 8 - 0
resources/views/index.blade.php

@@ -0,0 +1,8 @@
+
+@extends("layouts.app")
+
+@section("title", "Главная страница")
+
+@section("content")
+	<b>Здесь контент</b>
+@endsection

+ 23 - 0
resources/views/layouts/app.blade.php

@@ -0,0 +1,23 @@
+<!DOCTYPE html>
+<html>
+	<head>
+		<title>LaravelDemo - @yield('title')</title>
+		<style>
+			body {
+				font-family: sans-serif;
+				font-size: 16px;
+			}
+
+			.container {
+				max-width: 48rem;
+				margin: 0px auto;
+			}
+		</style>
+	</head>
+	<body>
+		<div class="container">
+			@yield('content')
+		</div>
+	</body>
+</html>
+

+ 1 - 3
routes/web.php

@@ -13,6 +13,4 @@ use Illuminate\Support\Facades\Route;
 |
 */
 
-Route::get('/', function () {
-    return view('welcome');
-});
+Route::view('/', 'index');