Skip to content

Add Float32Array eslint global #371

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

Merged
merged 1 commit into from
Mar 31, 2016
Merged

Conversation

n-riesco
Copy link
Contributor

  • Fixes the reported eslint errors in src/traces/surface/convert.js
    and src/traces/surface/convert.js.

* Fixes the reported eslint errors in `src/traces/surface/convert.js`
  and `src/traces/surface/convert.js`.
@etpinard
Copy link
Contributor

Is this necessary?

I haven't seen npm run lint complain about Float32Array globals.

As far as I know, eslint uses this list which indeed contains Float32Array.

@n-riesco
Copy link
Contributor Author

Perhaps there's something wrong with my setup. This is what I get when I run npm run lint:

user@host:~/github/plotly.js$ npm run lint

> plotly.js@1.7.1 lint /home/user/github/plotly.js
> eslint . || true


/home/user/github/plotly.js/src/traces/scattergl/convert.js
   48:24  error  'Float32Array' is not defined  no-undef
   64:24  error  'Float32Array' is not defined  no-undef
   65:21  error  'Float32Array' is not defined  no-undef
   75:24  error  'Float32Array' is not defined  no-undef
   76:21  error  'Float32Array' is not defined  no-undef
   86:24  error  'Float32Array' is not defined  no-undef
  218:8   error  'Float32Array' is not defined  no-undef
  219:35  error  'Float32Array' is not defined  no-undef
  270:25  error  'Float32Array' is not defined  no-undef
  326:45  error  'Float32Array' is not defined  no-undef
  332:41  error  'Float32Array' is not defined  no-undef
  355:25  error  'Float32Array' is not defined  no-undef
  356:23  error  'Float32Array' is not defined  no-undef
  357:23  error  'Float32Array' is not defined  no-undef
  448:45  error  'Float32Array' is not defined  no-undef
  454:41  error  'Float32Array' is not defined  no-undef
  494:42  error  'Float32Array' is not defined  no-undef
  517:41  error  'Float32Array' is not defined  no-undef

/home/user/github/plotly.js/src/traces/surface/convert.js
  104:30  error  'Float32Array' is not defined  no-undef
  140:41  error  'Float32Array' is not defined  no-undef
  186:25  error  'Float32Array' is not defined  no-undef
  187:25  error  'Float32Array' is not defined  no-undef
  188:25  error  'Float32Array' is not defined  no-undef
  255:37  error  'Float32Array' is not defined  no-undef

✖ 24 problems (24 errors, 0 warnings)

@etpinard
Copy link
Contributor

Hmm. Weird.

From the plotly.js/ root, can you enter:

 ./node_modules/.bin/eslint --version

?

@n-riesco
Copy link
Contributor Author

@etpinard I think the list you linked may explain it. Float32Array is not included in es5.

@n-riesco
Copy link
Contributor Author

user@host:~/github/plotly.js$ ./node_modules/.bin/eslint --version
v2.5.3

@etpinard
Copy link
Contributor

Ah. Nice find. I was running v2.3.0.

Thanks!

@etpinard etpinard merged commit 5c53f8f into plotly:master Mar 31, 2016
@n-riesco n-riesco deleted the eslint-float32array branch April 6, 2016 09:54
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.

2 participants