Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Webpack configuration #32

Merged
merged 4 commits into from
Nov 19, 2018
Merged

Conversation

arcticicestudio
Copy link
Contributor

Closes GH-31

Installed the first Webpack (1) plugins:

- "webpack-bundle-analyzer" (2) - Visualizes the size of Webpack output
  files with an interactive zoomable treemap.
- "git-revision-webpack-plugin" - Generates VERSION and COMMITHASH files
  during build based on a local Git repository.

References:
  (1) https://webpack.js.org
  (2) https://www.npmjs.com/package/git-revision-webpack-plugin
  (3) https://www.npmjs.com/package/webpack-bundle-analyzer

GH-31
Configured  the `webpack-bundle-analyzer` (1) plugin to generate a
"static" report with a JSON stats file stored in a newly created build
directory within the project root.

References:
  (1) https://github.com/webpack-contrib/webpack-bundle-analyzer

GH-31
Configured `git-revision-webpack-plugin` (1) to provide the version,
commit hash and branch as environment variables through through the
`webpack.DefinePlugin` (2).
The data is exposed through the following environment variables:

- `NORD_DOCS_GIT_VERSION`
- `NORD_DOCS_GIT_COMMITHASH`
- `NORD_DOCS_GIT_BRANCH`

References:
  (1) https://github.com/pirelenito/git-revision-webpack-plugin
  (2) https://webpack.js.org/plugins/define-plugin

GH-31
@arcticicestudio arcticicestudio changed the title Feature/gh 31 webpack configuration Webpack configuration Nov 19, 2018
@arcticicestudio arcticicestudio merged commit 7734d05 into develop Nov 19, 2018
@arcticicestudio arcticicestudio deleted the feature/gh-31-webpack-configuration branch November 19, 2018 21:13
@arcticicestudio arcticicestudio removed their assignment Nov 19, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants