node-templating-benchmark icon indicating copy to clipboard operation
node-templating-benchmark copied to clipboard

Use React.createFactory()

Open styfle opened this issue 8 years ago • 1 comments

I believe that you might be able to get better perf if you use React.createFactory() once, and then use the factory to pass props and render the component.

See this code for example usage.

I have not measured this so I'm just going off the idea that its less work in each request to reuse the same factory.

styfle avatar Nov 21 '17 01:11 styfle

Thoughts? @apapirovski @janit

styfle avatar Nov 21 '17 13:11 styfle