rev087/ng-inspector

"Controller-As" syntax has different results from older syntax

Open

#130 opened on 2015年8月11日

GitHub で見る
 (0 comments) (0 reactions) (0 assignees)JavaScript (787 stars) (100 forks)batch import
bughelp wanted

説明

Older Syntax:

angular.module('TestApp', [])
.controller('SampleCtrl', function($scope) {
    $scope.username = 'John Doe';
});

Result: Imgur


"Controller-As" syntax:

angular.module('TestApp', [])
.controller('SampleCtrl', function() {
    this.username = 'John Doe';
});

Result: Imgur

コントリビューターガイド