@recursive-robot/react-jsx-parser 1.39.0 → 1.40.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -1
- package/dist/cjs/react-jsx-parser.min.js +1 -1
- package/dist/cjs/react-jsx-parser.min.js.map +1 -1
- package/dist/es5/react-jsx-parser.min.js +1 -1
- package/dist/es5/react-jsx-parser.min.js.map +1 -1
- package/dist/helpers/functionUtilities.d.ts +6 -0
- package/dist/umd/react-jsx-parser.min.js +1 -1
- package/dist/umd/react-jsx-parser.min.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -52,7 +52,8 @@ Finally, a note about property bindings. The `JsxParser` can handle several type
|
|
|
52
52
|
- string-value binding, such as `stringProp="foo"`
|
|
53
53
|
- expression-binding, such as `calc={1 + 1}`
|
|
54
54
|
- named-value binding, such as `eventHandler={myEventHandler}` (note that this requires a match in `bindings`)
|
|
55
|
-
-
|
|
55
|
+
- [single statement arrow expressions](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/Arrow_functions#basic_syntax), such as `(item) => <p>{item.name}</p>`
|
|
56
|
+
- [multi-statement arrow functions](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/Arrow_functions#function_body), such as `(item) => { const { name } = item; return <p>{name}</p>; }`
|
|
56
57
|
|
|
57
58
|
This component also supports inline arrow function declarations (both expression-bodied and block-bodied), such as:
|
|
58
59
|
- `onClick={() => showToastNotification("Button clicked!") }`
|