Skip to content

Commit

Permalink
Revert "remove variables support (#30)"
Browse files Browse the repository at this point in the history
This reverts commit b742419.
  • Loading branch information
agubler committed Mar 22, 2020
1 parent b742419 commit 4a304b7
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/webpack.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ export default function webpackConfigFactory(args: any): Configuration {
const themesPath = args.themePath ? path.join(basePath, args.themePath) : path.join(basePath, 'src', 'theme');
const outputPath = path.join(basePath, 'output', 'theme');
const themes: string[] = args.themes;
const themeVariablesFiles = themes.map((theme) => {
return path.join(themesPath, theme, 'variables.css');
});

const postcssPresetConfig = {
browsers: ['last 2 versions', 'ie >= 10'],
Expand All @@ -29,13 +32,15 @@ export default function webpackConfigFactory(args: any): Configuration {
},
autoprefixer: {
grid: true
}
},
importFrom: themeVariablesFiles
};

const emitAll = emitAllFactory({
legacy: true,
inlineSourceMaps: false,
basePath: themesPath
basePath: themesPath,
additionalAssets: themeVariablesFiles
});

const tsLoaderOptions = {
Expand Down

0 comments on commit 4a304b7

Please sign in to comment.