- Centralize the app infrastructure (tooling and libs needed to build and develop an app) such that the consumers of
buildkit
are decoupled from maintaining the infrastructure on a project by project basis - Provide sensible defaults that can be extended
- First class support for Webstorm's builtin tools/plugins (e.g. remote debugging, running the tests or apps in Webstorm's runner etc.)
- "Absolute" import/require paths relative to
/src
directory (e.g.import foo from 'src/foo
)
Haven't published to NPM yet, but for now can experiment by installing via git url.
"devDependencies": {
"buildkit": "git://github.com/epikhighs/buildkit.git"
}
- agreed upon directory structure and file naming scheme
- project files go into
/src
- test files are co-located with source files and ends with
*.test.js
- copies over config from build repo or make it read config from node_modules. Can prob create a
node_modules/.bin
script that copies over base configs fromnode_modules
. This script would be run as part of thenpm run prod-build
step so on CI build server it would automatically get the config it needs. And in webpack config's use case, can make webpack config point to a file that provides overrides. - .babelrc, webpack config
- need a node.js script that installs common packages. Can probably read from a config file that's there per project that provides blacklist/whitelist on which packages it needs.
- create a repo
npm init
npm i -D git://github.com/epikhighs/buildkit.git
- this step auto-installs all package.json
dependencies
frombuildkit
npx buildkit init
- copies over base configs (babel/webpack/storybook)
- update
package.json
's npm scripts - "server": "webpack-dev-server --config ./webpack.base.babel.js",
-
initial scope
- webpack
- babel
-
foundational
- babel
- cross env
- npm-check
- react hot loader
- storybook
- webpack
-
code quality
- chai
- eslint
- enzyme
- istanbul/nyc
- mocha
- sinon
-
run time libs
- ramda
- react
- recompose
- styled comp
-
optional libs
- redux
- redux dev tool
- redux saga
- reselect
- must install packages to
dependencies
and notdevDependencies
for all packages that are intended to be auto installed into consumer's repo, else the consumer ofbuildkit
can't automatically get the packages inbuildkit
when runningnpm i
from the consumer's repo. Typical example will bewebpack
andbabel
should be auto installed into consumer's repo so those will go into the run-timedependencies
. But maybe I want to run some mocha tests to test outbuildkit
specific behavior, then mocha should be installed todevDependencies
. But mocha is a bad example b/c I'd want mocha to be auto installed too as the testing framework of choice so that'd actually go insidedependencies
.