Skip to content

Commit d5a34fc

Browse files
Making sure the JS standard is consistent (ESM)
1 parent 3c770b6 commit d5a34fc

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

src/index.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import nesting from 'postcss-nesting';
44
const functionalSelectorMatch = /(^|[^\w-])(%[_a-zA-Z]+[_a-zA-Z0-9-]*)([^\w-]|$)/i;
55

66
// plugin
7-
module.exports = (rawopts) => {
7+
const postcssExtendRule = (rawopts) => {
88
// options ( onFunctionalSelector, onRecursiveExtend, onUnusedExtend)
99
const opts = Object(rawopts);
1010
const extendMatch = opts.name instanceof RegExp
@@ -144,4 +144,6 @@ function getSelectorIdMatch(selectorIds, postcss) {
144144
return new RegExp(`(^|[^\\w-]!.!#)(${escapedSelectorIds})([^\\w-]|$)`, '');
145145
}
146146

147-
module.exports.postcss = true;
147+
postcssExtendRule.postcss = true;
148+
149+
export default postcssExtendRule;

0 commit comments

Comments
 (0)