Initial Sinatra project strucutre
This commit is contained in:
11
views/index.erb
Normal file
11
views/index.erb
Normal file
@ -0,0 +1,11 @@
|
||||
<p>This is a test.</p>
|
||||
|
||||
<% if items.length > 0 %>
|
||||
<ul>
|
||||
<% items.each do |item| %>
|
||||
<li><%= item.name %></li>
|
||||
<% end %>
|
||||
</ul>
|
||||
<% else %>
|
||||
<p>There are no items to display.</p>
|
||||
<% end %>
|
13
views/layout.erb
Normal file
13
views/layout.erb
Normal file
@ -0,0 +1,13 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title><%= title %> | Raven</title>
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/skeleton/2.0.4/skeleton.min.css">
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.1/jquery.min.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<%= yield %>
|
||||
</body>
|
||||
</html>
|
Reference in New Issue
Block a user