Below is a of the discussion from this week’s JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser.
https://www.javascript.com chat (agenda, Slack Transcript)
Have a topic for discussion for the next meeting? Leave a suggested edit on next week’s agenda.
Agenda: ReactReact React is a JavaScript library that makes it easy to reason about, construct, and maintain stateless and stateful user interfaces.
https://reactjs.org HooksHooks In WordPress theme and development, hooks are functions that can be applied to an action or a Filter in WordPress. Actions are functions performed when a certain event occurs in WordPress. Filters allow you to modify certain functions. Arguments used to hook both filters and actions look the same. offering for wordpress/data
There’s a bit of discussion surrounding implementing React Hooks in the WordPress use of javascript. Here’s some take-ways/actions from the discussion:
- Experiment with a
useSelectlimited example to port an existing component (initial experiments owned by @nerrad) - Consider the broader context of higher-order components, and the impact of hooks:
- Which existing higher-order components can be ported? All of them?
- Do the interfaces change in porting to hooks?
- Would we ever find reason to create new higher-order components?
Please assist in working through this discussion. You can contribute thoughts in the related github issue.