thegreenwebfoundation / co2.js

An npm module for accessing the green web API, and estimating the carbon emissions from using digital services
https://developers.thegreenwebfoundation.org/
Other
421 stars 55 forks source link

Format code using default recommended eslint settings. #13

Closed soulgalore closed 4 years ago

soulgalore commented 4 years ago

Ok you need to merge this manually since my class change went through is it ok?

I've set it up using default eslint settings, only exception is unused variables, I turned that rule off for now thinking we can cleanup the code later. In VSCode the setting Is automatically picked, lets see if we can make it happened your editor too,

npm run lint runs the tests, npm run lint:fix fixes the ones that can be automatically fixed. Then we can add the check to Travis + you can also make pre commit hook that either checks or auto format fit lint:fix depending on how you wanna work.

soulgalore commented 4 years ago

Else I can update them tonight. I think easiest is just to take everything master and reformat those two files. Now I'm off for a couple of hours :)