Skip to content

Commit

Permalink
fix: define window to avoid breakage when using it in the config fi…
Browse files Browse the repository at this point in the history
…le (#142)
  • Loading branch information
sarahdayan committed Jul 29, 2020
1 parent 0b69b32 commit ac30515
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions postcss.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
/* eslint-disable import/no-commonjs */

// When the configuration file refers to `window`, we need to shim it so it
// doesn't break when processed with Node during the build step.
window = global;

require('module-alias/register');
require('ignore-styles');

const postcssPresetEnv = require('postcss-preset-env');
const postcssInjectCssVariables = require('postcss-inject-css-variables');
const {
Expand Down

0 comments on commit ac30515

Please sign in to comment.