In Rails ERB, you can suppress newlines by adding a trailing hyphen to tags:
<% for @item in @items -%> <%= @item %>
When you write a template, you could open the ul hardcoded in the template and looping trought items en returning there value with the in it.
As far as i know there isn't a default function for that.