 
         views = {}
         $(steps).each (i, el) ->
-          _modal = $(modal).clone()
+          _modal = $('<div>')
+          $(_modal).html $(modal).html()
           $(el).attr('data-modal-step', i)
 
           # replace top bar buttons with relevant buttons

          catch e
            json = { error: "We're sorry, there was an error." }
          html = _.template BBM_TEMPLATE, title: "Oops!", content: "<p>#{json.error}</p>"
          $(this).html html

        complete: (object) =>
          # if this request was clicked while this request was loading,

$ ->  

  $('script[data-path]').each ->
    $(this).modal 'load' if $(this).attr("data-precache")

  $(document.body).on 'click', '*[data-open-modal]', (e) ->
    e.preventDefault()
