Use native ES6 classes over Uptown #166
Closed
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.
This removes the dependency on Uptown and uses ES6 classes which are available in Node 4, the lowest Node we support.
Transpilation is done for the browser distribution to maintain compatibility for all browsers.
I've also added use of const/let over var while I was at it.
DO NOT MERGE
As of right now, this change would break downstream minim-api-description and minim-parse-result due to babel/babel#6299 (Babel-transpiled class can't extend from native class), a fix for this can be found in Babel 7 (there are betas available but no final release). We could move peasant and other minim libraries to Babel 7.
An alternative, perhaps we can move minim-* packages to work similar to minim. Where the node sources are not transpiled and instead written for plain Node 4 and then just transpired for the web distribution.