UNPKG

tpa-style-webpack-plugin

Version:

A Webpack plugin that handles wix tpa styles, it separates static css file that injects dynamic style at runtime.

23 lines 1.09 kB
var __assign = (this && this.__assign) || function () { __assign = Object.assign || function(t) { for (var s, i = 1, n = arguments.length; i < n; i++) { s = arguments[i]; for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p]; } return t; }; return __assign.apply(this, arguments); }; import { getProcessedCssWithConfig, getStaticCssWithConfig } from './standalone'; export function getProcessedCss(styles, options) { var injectedData = '__COMPILATION_HASH__INJECTED_DATA_PLACEHOLDER'; var processedCssConfig = __assign(__assign({}, injectedData), { compilationHash: '__COMPILATION_HASH__' }); return getProcessedCssWithConfig(processedCssConfig, styles, options); } export function getStaticCss(options) { var injectedData = '__COMPILATION_HASH__INJECTED_STATIC_DATA_PLACEHOLDER'; var cssConfig = __assign(__assign({}, injectedData), { compilationHash: '__COMPILATION_HASH__' }); return getStaticCssWithConfig(cssConfig, options); } //# sourceMappingURL=main.js.map