Sitepoint demo app for learning to use Sinatra
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

10 lines
364 B

  1. %li.list
  2. %h2= list.name
  3. %form.new(action="/#{list.id}" method="POST")
  4. %input(type="text" name="task[name]")
  5. %ul.tasks
  6. - list.tasks.each do |task|
  7. = render(:haml, :task, locals: { task: task })
  8. %form.destroy(action="/list/#{list.id}" method="POST")
  9. %input(type="hidden" name="_method" value="DELETE")
  10. %input(type="submit" value="✗")