- # non-working example
- # check http://www.pastie.org/466338 for the working version
- require 'rubygems'
- require 'innate'
- class Test
- include Innate::Node
- map '/'
- TEMPLATE = '
- <html>
- <head>
- <title><%= @title %></title>
- </head>
- <body>
- <h1><%= @title %></h1>
- </body>
- </html>'.gsub(/^ /, '')
- def index
- @title = 'Search'
- TEMPLATE
- end
- def list
- @title = 'List'
- TEMPLATE
- end
- end
- Innate.start