elm-community / elm-webgl

Moved to elm-explorations/webgl

Home Page:http://package.elm-lang.org/packages/elm-explorations/webgl/latest

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Unify code formatting in the Native module

w0rm opened this issue · comments

I'm not sure if there is a preferred way to format JavaScript, I am happy with any coding style but it has to be consistent.

Perhaps we can as well add an eslint config or something.

I think this is a fine idea. Most of the original JS was written by @johnpmayer... maybe he has a suggested style?

The style I use personally is the strictest settings for JSHint, but it looks like the tool has changed a bit since the last time I used it.

I added an eslint config for the most recent version of eslint. The cool thing about it, is that you can run eslint src/Native --fix and it will fix the formatting itself.

It also discovered a bug in throw error('No info available for: ' + attribute.type); where error should be new Error