Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Except for the HTML template functionality, I basically rewrote the entire thing:
Babel to the rescue!
Instead of using the
ng-annotate-loader
for webpack, it now uses theangularjs-annotate
plugin for Babel:EVERYTHING is "private/protected" now
I'm doing this on several plugins and projext services now: Methods and properties that weren't intended to be used outside its class are now prefixed with an underscore (
_
), to mark them as "protected/private".Sometimes I consider some methods/properties to be "ok" as "public" as they may be of utility for someone, but it wasn't until a few releases ago that I realized that by thinking that, changing those methods/properties, would require a breaking release, when there was no "real" reason for those things to be "public".
So, from now on, use events and reducers and try to stay away from methods and properties prefixed with underscore.
Dependencies up to date
All production and development dependencies were updated to their latest version.
Now, there's a special mention: ESLint. It latest version is
v5
, but the Airbnb preset I use is still not compatible with it, so I updated ESLint to the last version beforev5
:v4.19.1
.I also updated a few things on the
.eslintrc
after getting the Airbnb preset last version:lines-between-class-members
: I disabled this rule because I already fill the space between methods with comments, so I see not reason for it.operator-linebreak
: I changed the default value from the Airbnb,before
, toafter
. The convention I use and which I believe is easier to read is with the operators at the end of the line.hooks
instead ofinstall-hooks
The
yarn
/npm
script to install the repositories hook has been changed to justhooks
.How should it be tested manually?
This shouldn't be breaking, so try to build your AngularJS app using this branch, it should be fine.
And of course...