Skip to content

Commit e58df31

Browse files
committed
docs: document utility functions
1 parent 61634ab commit e58df31

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

src/createObjectExpression.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ import BabelTypes, {
77
type InputObjectType = {
88
[key: string]: string | InputObjectType
99
};
10+
11+
/**
12+
* Creates an AST representation of an InputObjectType shape object.
13+
*/
1014
const createObjectExpression = (t: BabelTypes, object: InputObjectType): ObjectExpression => {
1115
const properties = [];
1216

src/resolveStringLiteral.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ import type {
88
StyleModuleImportMapType
99
} from './types';
1010

11+
/**
12+
* Updates the className value of a JSX element using a provided styleName attribute.
13+
*/
1114
export default (path: Object, styleModuleImportMap: StyleModuleImportMapType, styleNameAttribute: JSXAttribute): void => {
1215
const classNameAttribute = path.node.openingElement.attributes
1316
.find((attribute) => {

0 commit comments

Comments
 (0)