How to integrate React project in JSF framework?

I was trying to integrate a React project into a JSF framework as a module
I’m still looking for the correct path to take ?
what should I do and use to have the best performance and behaviors ?
Thanks in advance.

I tried to use webpack to create a dist (bundle js) and then call that bundle as a script in xhtml page
it works, but I want to know if there’s a better way to do it.