   render: ->
     console.log "rendering view", @
     @_template = new Template(JST[ @tpl_path() ])
-    $(@el).html(@_template.render(@))
+
+    # use an optional [dynamic] selector
+    el = null
+    if @selector?
+      if _.isFunction(@selector)
+        el = @selector()
+      else
+        el = el
+    else
+      el = @el
+
+    @setElement(el)
+    @$el.html(@_template.render(@))
     @
 
   # proxy for Stark.state#transition

      if ! (_.any(new_state.views, (n)-> v instanceof n) && _.any(new_state.no_redraw, (n)-> v instanceof n))
        # only dispose of view IF NOT required by new state
        console.log "disposing of", v
        v.$el.html("")
        v.undelegateEvents()

  bind_app_events: ->
    _.each @app_events, (cb, key) ->

    _.each @app_events, (cb, key) ->
      @app.subscribe(key, cb)
    , @

  dispose: ->
    @$el.html("")
    @undelegateEvents()
    for v in @views
      v.dispose()

