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

[internal] Replace var with let in ui/public A-D #6907

Merged
merged 1 commit into from
Apr 14, 2016

Conversation

epixa
Copy link
Contributor

@epixa epixa commented Apr 13, 2016

This change was applied to any .js files under directories beginning
with a through d in src/ui/public.

This was an automatic replacement from var to let for any variable
declaration that doubles as the initial assignment. Ultimately we want
most of these to be converted to const, but this commit is so large that
it warrants breaking each step of automation up into its own commit.

For example:

var foo = 'bar'; becomes let foo = 'var';

This was accomplished by replacing:
find: var ([a-zA-Z_$][0-9a-zA-Z_$]*)(\s+)=
replace: let $1$2=

@epixa
Copy link
Contributor Author

epixa commented Apr 13, 2016

jenkins, test it

@epixa epixa added the review label Apr 13, 2016
@epixa epixa assigned spalger and unassigned epixa Apr 13, 2016
@spalger
Copy link
Contributor

spalger commented Apr 13, 2016

LGTM

@spalger spalger assigned epixa and unassigned spalger Apr 13, 2016
This change was applied to any .js files under directories beginning
with `a` through `d` in src/ui/public.

This was an automatic replacement from var to let for any variable
declaration that doubles as the initial assignment. Ultimately we want
most of these to be converted to const, but this commit is so large that
it warrants breaking each step of automation up into its own commit.

For example:

`var foo = 'bar';` becomes `let foo = 'var';`

This was accomplished by replacing:
find: `var ([a-zA-Z_$][0-9a-zA-Z_$]*)(\s+)=`
replace: `let $1$2=`
@epixa epixa assigned panda01 and epixa and unassigned epixa and panda01 Apr 14, 2016
@@ -1,5 +1,5 @@
import uiModules from 'ui/modules';
var module = uiModules.get('kibana');
let module = uiModules.get('kibana');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this just github being silly that these aren't highlighted?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Github, yeah.

@panda01
Copy link
Contributor

panda01 commented Apr 14, 2016

It would appear it is github being silly. LGTM!

@panda01 panda01 assigned epixa and unassigned panda01 Apr 14, 2016
@epixa epixa merged commit fa4c6b0 into elastic:master Apr 14, 2016
@epixa epixa deleted the uiletconst3 branch April 14, 2016 14:25
epixa added a commit that referenced this pull request Apr 14, 2016
---------

**Commit 1:**
[internal] Replace var with let in ui/public A-D

This change was applied to any .js files under directories beginning
with `a` through `d` in src/ui/public.

This was an automatic replacement from var to let for any variable
declaration that doubles as the initial assignment. Ultimately we want
most of these to be converted to const, but this commit is so large that
it warrants breaking each step of automation up into its own commit.

For example:

`var foo = 'bar';` becomes `let foo = 'var';`

This was accomplished by replacing:
find: `var ([a-zA-Z_$][0-9a-zA-Z_$]*)(\s+)=`
replace: `let $1$2=`

* Original sha: 4c535f6
* Authored by Court Ewing <court@epixa.com> on 2016-04-12T22:18:38Z
elastic-jasper added a commit that referenced this pull request Apr 14, 2016
---------

**Commit 1:**
[internal] Replace var with let in ui/public A-D

This change was applied to any .js files under directories beginning
with `a` through `d` in src/ui/public.

This was an automatic replacement from var to let for any variable
declaration that doubles as the initial assignment. Ultimately we want
most of these to be converted to const, but this commit is so large that
it warrants breaking each step of automation up into its own commit.

For example:

`var foo = 'bar';` becomes `let foo = 'var';`

This was accomplished by replacing:
find: `var ([a-zA-Z_$][0-9a-zA-Z_$]*)(\s+)=`
replace: `let $1$2=`

* Original sha: 4c535f6
* Authored by Court Ewing <court@epixa.com> on 2016-04-12T22:18:38Z
epixa added a commit that referenced this pull request Apr 14, 2016
epixa added a commit that referenced this pull request Apr 14, 2016
@epixa epixa added v4.5.2 and removed v4.5.1 labels May 14, 2016
@epixa epixa added v4.5.4 and removed v4.5.2 labels Jul 21, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants