Galooshi / happo

Visual diffing in CI for user interfaces
504 stars 16 forks source link

Update import-js config for all packages #194

Closed trotzig closed 7 years ago

trotzig commented 7 years ago

To make import-js 1 work correctly, we need to configure it a little.

Most of our packages are node projects using CommonJS imports and exports, so I created a root .importjs.js that package-specific config then inherited. These projects also transpile code into a lib folder, plus have test files in __tests__ folders, so it was easy to set up the excludes configuration (which controls what files import-js won't import for you).

The happo-viewer package was treated differently since it mostly has client-side React code where we use es6 imports and exports.

trotzig commented 7 years ago

Whoops, I cherry-picked this into #198 as well, thinking I never pushed this branch. I'll merge it from there instead.