UNPKG

380 BJavaScriptView Raw
1'use strict';
2const processors = require('./lib/decl');
3
4function pluginCreator() {
5 return {
6 postcssPlugin: 'postcss-merge-longhand',
7
8 OnceExit(css) {
9 css.walkRules((rule) => {
10 processors.forEach((p) => {
11 p.explode(rule);
12 p.merge(rule);
13 });
14 });
15 },
16 };
17}
18
19pluginCreator.postcss = true;
20module.exports = pluginCreator;