Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Request] Rename variable name #400

Closed
wants to merge 250 commits into from

Conversation

ilyanew
Copy link
Contributor

@ilyanew ilyanew commented May 10, 2018

Rename variable 'final' to 'fin'. Because 'final' is reserved word in javascript. And it breaks down 'yui compressor'.
Please find the list of reserved words in js:
https://www.w3schools.com/js/js_reserved.asp
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Lexical_grammar

zloirock added 30 commits May 7, 2018 23:02
- use `isArray` instead of `isConcatSpreadable`
- set the target length explicitly
@loganfsmyth
Copy link
Contributor

Not the maintainer of this project, but I'll just say that final hasn't been a reserved word since 2009 when the ES5 spec was released, so at a minimum this is still a bug with yui compressor for any modern code.

@ilyanew
Copy link
Contributor Author

ilyanew commented May 11, 2018

Yeap, You are absolutely right. 'Yui compressor' is too old :)
But if you merge this PR, 'core-js' can be easily transformed to es3. I believe that it will only a benefit for 'core-js'.

I would be really grateful!
You would have helped me out very much.

@zloirock
Copy link
Owner

Please, leave only this commit and I'll merge it.

@ilyanew
Copy link
Contributor Author

ilyanew commented May 14, 2018

There are some issues with newlines in a few files. :)
But I changed variable name only in 'modules/es6.typed.array-buffer.js' file.
Or should I create new PR?

@zloirock
Copy link
Owner

Just do git rebase -i and drop the rest commits.

@ilyanew ilyanew force-pushed the rename-variable-name branch from 3f296aa to 7d0f371 Compare May 14, 2018 10:37
@ilyanew ilyanew closed this May 14, 2018
@ilyanew
Copy link
Contributor Author

ilyanew commented May 14, 2018

Sorry, I've faced some problems with Rebasing. Therefore decided to create new PR #402

@zloirock
Copy link
Owner

Ok, thanks -)

@zloirock
Copy link
Owner

I you wanna contribute to this project, you can try to improve linting settings for prevent problems like this in the future.

@ilyanew ilyanew deleted the rename-variable-name branch May 21, 2018 07:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants