You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: cli/README.md
+9-9
Original file line number
Diff line number
Diff line change
@@ -116,6 +116,7 @@ In addition to the [general configuration](../README.md#general-configuration) f
116
116
```jsonp
117
117
{
118
118
"codeConnect": {
119
+
"parser": "react",
119
120
"include": [],
120
121
"exclude": ["test/**", "docs/**", "build/**"],
121
122
"importPaths": {
@@ -246,7 +247,6 @@ export function ButtonExample({ label, disabled, type }) {
246
247
247
248
The `figma` import contains helpers for mapping all sorts of properties from design to code. They work for simple mappings where only the naming differs between Figma and code, as well as more complex mappings where the type differs. See the below reference for all the helpers that exist and the ways you can use them to connect Figma and code components using Code Connect.
248
249
249
-
250
250
### figma.connect
251
251
252
252
`figma.connect()` has two signatures for connecting components.
@@ -288,16 +288,15 @@ figma.boolean('Has Icon', {
288
288
true: <Icon />,
289
289
false: <Spacer />,
290
290
})
291
-
292
291
```
293
292
294
293
In some cases, you only want to render a certain prop if it matches some value in Figma. You can do this either by passing a partial mapping object, or setting the value to `undefined`.
295
294
296
295
```tsx
297
296
// Don't render the prop if 'Has label' in figma is `false`
`figma.children()` can be used with a single wildcard '*' character, to partially match names or to render any nested child. Wildcards cannot be used with the array argument. Matches are case sensitive.
423
+
`figma.children()` can be used with a single wildcard '\*' character, to partially match names or to render any nested child. Wildcards cannot be used with the array argument. Matches are case sensitive.
0 commit comments