JavaScript

JavaScript

Made by DeepSource

Use reference modules with the getter syntax JS-0514

Style
Minor
angularjs

When using a module, avoid using a variable and instead use chaining with the getter syntax. It produces readable code and avoids variable collisions or leaks.

Bad Practice

app.controller('MyController', function () {
    // ...
});

Recommended

angular.module('myModule').controller('MyController', function () {
    // ...
});

References