UJS Plugin - apply_behaviour Question

Anyone using the Unobtrusive Javascript for Ruby On Rails Plugin?

I have some code that looks like this.

<% apply_behaviour ‘select:click’ do |page, element, event|
page.insert_html :top, ‘the_list’, “

  • hi

  • end %>

    What I would like to do is list the element.value rather than the string
    “hi” but I’m a bit confused on how to do this. I’m guessing this is
    something obvious that I’m missing.

    Thanks,
    Mike