Sha256: 7bda4c0e0b6a3d78741c500878ef35e4e70f35bc374e5c3ab327cd6ed9693f1c

Contents?: true

Size: 285 Bytes

Versions: 42

Compression:

Stored size: 285 Bytes

Contents

# //= require ./angular_scoped_model
@ViewModels ||= {}
class @AngularViewModel extends AngularScopedModel
  # Automatically registers the controller to the module
  @register: (app, name) ->
    name ?= @name || @toString().match(/function\s*(.*?)\(/)?[1]
    app.controller? name, @

Version data entries

42 entries across 42 versions & 1 rubygems

Version Path
material_raingular-0.2.6 lib/assets/javascripts/super_classes/angular_view_model.coffee
material_raingular-0.2.5 lib/assets/javascripts/super_classes/angular_view_model.coffee