@@ -439,7 +439,7 @@ Output (example):
439439> Identifiers are exported
440440
441441``` js
442- exports .locals = {
442+ module . exports .locals = {
443443 className: " _23_aKvs-b8bW2Vg3fwHozO" ,
444444 subClass: " _13LGdX8RMStbBE9w-t0gZ1" ,
445445};
@@ -468,7 +468,7 @@ When declaring a local class name, you can compose it from one or more other loc
468468This does not alter the final CSS output, but the generated ` subClass ` will include both class names in its export.
469469
470470``` js
471- exports .locals = {
471+ module . exports .locals = {
472472 className: " _23_aKvs-b8bW2Vg3fwHozO" ,
473473 subClass: " _13LGdX8RMStbBE9w-t0gZ1 _23_aKvs-b8bW2Vg3fwHozO" ,
474474};
@@ -1547,7 +1547,7 @@ function addReplacements(resourcePath, imports, exportsJson, replacements) {
15471547 // canonical values map and all exports JSON verbatim
15481548 canonicalValuesMap[identifier] = classNames;
15491549
1550- allExportsJson[resourcePath] = allExportsJson[resourcePath] || {};
1550+ allExportsJson[resourcePath] || = {};
15511551 allExportsJson[resourcePath][localName] = classNames;
15521552 }
15531553 }
@@ -1609,7 +1609,7 @@ class CssModulesJsonPlugin {
16091609
16101610 const [, resourcePath , localName ] = identifier .match (IDENTIFIER_REGEX );
16111611
1612- allExportsJson[resourcePath] = allExportsJson[resourcePath] || {};
1612+ allExportsJson[resourcePath] || = {};
16131613 allExportsJson[resourcePath][localName] = adjustedClassNames;
16141614 }
16151615
@@ -2323,8 +2323,8 @@ File treated as `CSS Module`.
23232323Using both ` CSS Module ` functionality as well as SCSS variables directly in JavaScript.
23242324
23252325``` jsx
2326- import * as styles from " Component.module.scss" ;
2327- import * as svars from " variables.scss" ;
2326+ import * as _styles from " ./ Component.module.scss" ;
2327+ import * as _svars from " ./ variables.scss" ;
23282328
23292329// Render DOM with CSS modules class name
23302330// <div className={styles.componentClass}>
@@ -2333,7 +2333,7 @@ import * as svars from "variables.scss";
23332333
23342334// Somewhere in JavaScript canvas drawing code use the variable directly
23352335// const ctx = mountsCanvas.current.getContext('2d',{alpha: false});
2336- ctx .fillStyle = ` ${ svars .colorBackgroundCanvas } ` ;
2336+ // ctx.fillStyle = `${svars.colorBackgroundCanvas}`;
23372337```
23382338
23392339## Contributing
0 commit comments