docs: react section for plugins

Massimo Melina committed Jun 18, 2023 at 20:13 UTC 8d709a6074c45fa9853639cccb675cc1380c9b72
1 file changed +19 -1
dev-plugins.md
+19 -1
@@ -298,7 +298,25 @@ Published plugins are required to specify the `apiRequired` property.
298
299 It is possible to publish different versions of the plugin to be compatible with different versions of HFS.
300 To do that, just have your other versions in branches with name starting with `api`.
301 -HFS will scan through them in inverted alphabetical order searching for a compatible one.
301 +HFS will scan through them in inverted alphabetical order searching for a compatible one.
302 +
303 +## React developers
304 +
305 +Most React developers are used to JSX, which is not (currently) supported here.
306 +If you want, you can try solutions to JSX support, like transpiling.
307 +Anyway, React is not JSX, and can be easily used without.
308 +
309 +Any time you in JSX you do
310 +```jsx
311 +<button onClick={() => console.log('hi')}>Say hi</button>
312 +```
313 +
314 +This is just transalted to
315 +```js
316 +h('button', { onClick: () => console.log('hi') }, 'Say hi')
317 +```
318 +
319 +Where `h` is just `import { createElement as h } from 'react'`.
320
321 ## API version history
322