Slim, Liquid templates
This commit is contained in:
@@ -7,18 +7,18 @@
|
||||
<% customers.each do |customer| %>
|
||||
<dl>
|
||||
<dt>Name:</dt>
|
||||
<dd><%= customer[:name] %></dd>
|
||||
<dd><%= customer['name'] %></dd>
|
||||
<dt>Age:</dt>
|
||||
<dd><%= customer[:age] %></dd>
|
||||
<dd><%= customer['age'] %></dd>
|
||||
<dt>Address:</dt>
|
||||
<dd>
|
||||
<%= customer[:zip] %>
|
||||
<%= customer[:country] %>
|
||||
<%= customer[:city] %>
|
||||
<%= customer[:address] %>
|
||||
<%= customer['zip'] %>
|
||||
<%= customer['country'] %>
|
||||
<%= customer['city'] %>
|
||||
<%= customer['address'] %>
|
||||
</dd>
|
||||
<dt>Employer:</dt>
|
||||
<dd><%= customer[:employer] %></dd>
|
||||
<dd><%= customer['employer'] %></dd>
|
||||
</dl>
|
||||
<% end %>
|
||||
</body>
|
||||
|
||||
@@ -7,18 +7,18 @@
|
||||
<% customers.each do |customer| %>
|
||||
<dl>
|
||||
<dt>Name:</dt>
|
||||
<dd><%= customer[:name] %></dd>
|
||||
<dd><%= customer['name'] %></dd>
|
||||
<dt>Age:</dt>
|
||||
<dd><%= customer[:age] %></dd>
|
||||
<dd><%= customer['age'] %></dd>
|
||||
<dt>Address:</dt>
|
||||
<dd>
|
||||
<%= customer[:zip] %>
|
||||
<%= customer[:country] %>
|
||||
<%= customer[:city] %>
|
||||
<%= customer[:address] %>
|
||||
<%= customer['zip'] %>
|
||||
<%= customer['country'] %>
|
||||
<%= customer['city'] %>
|
||||
<%= customer['address'] %>
|
||||
</dd>
|
||||
<dt>Employer:</dt>
|
||||
<dd><%= customer[:employer] %></dd>
|
||||
<dd><%= customer['employer'] %></dd>
|
||||
</dl>
|
||||
<% end %>
|
||||
</body>
|
||||
|
||||
@@ -6,14 +6,14 @@
|
||||
- customers.each do |customer|
|
||||
%dl
|
||||
%dt Name:
|
||||
%dd= customer[:name]
|
||||
%dd= customer['name']
|
||||
%dt Age:
|
||||
%dd= customer[:age]
|
||||
%dd= customer['age']
|
||||
%dt Address:
|
||||
%dd
|
||||
= customer[:zip]
|
||||
= customer[:country]
|
||||
= customer[:city]
|
||||
= customer[:address]
|
||||
= customer['zip']
|
||||
= customer['country']
|
||||
= customer['city']
|
||||
= customer['address']
|
||||
%dt Employer:
|
||||
%dd= customer[:employer]
|
||||
%dd= customer['employer']
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Customers List</title>
|
||||
</head>
|
||||
<body>
|
||||
{% for customer in customers %}
|
||||
<dl>
|
||||
<dt>Name:</dt>
|
||||
<dd>{{ customer.name }}</dd>
|
||||
<dt>Age:</dt>
|
||||
<dd>{{ customer.age }}</dd>
|
||||
<dt>Address:</dt>
|
||||
<dd>
|
||||
{{ customer.zip }}
|
||||
{{ customer.country }}
|
||||
{{ customer.city }}
|
||||
{{ customer.address }}
|
||||
</dd>
|
||||
<dt>Employer:</dt>
|
||||
<dd>{{ customer.employer }}</dd>
|
||||
</dl>
|
||||
{% endfor %}
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,18 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>{{ title }}</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Hello, {{ username }}!</h1>
|
||||
<p>
|
||||
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
|
||||
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim
|
||||
veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea
|
||||
commodo consequat. Duis aute irure dolor in reprehenderit in voluptate
|
||||
velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat
|
||||
cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id
|
||||
est laborum.
|
||||
</p>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,19 @@
|
||||
doctype html
|
||||
html
|
||||
head
|
||||
title Customers List
|
||||
body
|
||||
- customers.each do |customer|
|
||||
dl
|
||||
dt Name:
|
||||
dd = customer['name']
|
||||
dt Age:
|
||||
dd = customer['age']
|
||||
dt Address:
|
||||
dd
|
||||
== customer['zip']
|
||||
== customer['country']
|
||||
== customer['city']
|
||||
== customer['address']
|
||||
dt Employer:
|
||||
dd = customer['employer']
|
||||
@@ -0,0 +1,14 @@
|
||||
doctype html
|
||||
html
|
||||
head
|
||||
title = title
|
||||
body
|
||||
h1 Hello, #{username}!
|
||||
p
|
||||
| Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
|
||||
| tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim
|
||||
| veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea
|
||||
| commodo consequat. Duis aute irure dolor in reprehenderit in voluptate
|
||||
| velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint
|
||||
| occaecat cupidatat non proident, sunt in culpa qui officia deserunt
|
||||
| mollit anim id est laborum.
|
||||
Reference in New Issue
Block a user