agoric-labs / PlaygroundVat

OBSOLETE prototype Vat host: use SwingSet instead
Apache License 2.0
30 stars 5 forks source link

ESLint changes to src/main.js Also, turn off for...of rule #60

Closed katelynsills closed 5 years ago

katelynsills commented 5 years ago

Errors

screen shot 2019-02-22 at 9 39 28 am

Fixes

  1. Turn off the for...of rule. Mark says for...of is now very performant and this is an outdated message.
  2. Remove unused imports
  3. Use const when possible - lines 50 and 51 I go back and forth on, since it's less elegant.
  4. Switch to destructuring if possible. If not, disable.
  5. for...of to forEach when it seems easily doable
  6. allow intentional unused args
  7. Switch to camelCase
  8. Allow getAddressesForHostID as is. We may revisit it later, but for now, the logic is not easily expressed outside of a for...of
warner commented 5 years ago

Oh and feel free to land the .eslintrc.js change first, maybe some of those issues go away when eslint stops complaining about them.