     if instance.cls isnt $.noop then $root.addClass instance.cls()
 
     $root.data instance.attr(), instance
+
+  _createPluginAPIAdditions = (name, namespace) ->
+    evt: _.memoize (name) -> "#{name}#{namespace.toString 'event'}"
+    attr: _.memoize (name) ->
+      name = if name? then "-#{name}" else ''
+      namespace.toString('data') + name
+    cls: if namespace.toString('class') is namespace.toString() then $.noop else
+      _.memoize (name) ->
+        name = if name? then "-#{name}" else ''
+        namespace.toString('class') + name
+    debugLog: if namespace.debug is off then $.noop else
+      -> hlf.debugLog namespace.toString('log'), arguments...
 
   _.extend hlf,
 

      if createOptions.baseMixins?
        hlf.applyMixins instance, namespace, createOptions.baseMixins...
      hlf.applyMixin instance, namespace, apiMixins.base
      otherMixins = _.chain(apiMixins)
        .filter(mixinFilter, instance)
        .values()
        .without(apiMixins.base)
        .value()
      hlf.applyMixins instance, namespace, otherMixins...
    if _.isFunction(instance.init) then instance.init()

      safeName = "#{@toString()}#{name[0].toUpperCase()}#{name[1..]}"
      namespace = createOptions.namespace
      
      apiAdditions = _createPluginAPIAdditions name, namespace
        
      if createOptions.apiClass?
        apiClass = namespace.apiClass = createOptions.apiClass
