How to dynamically create new state, functions, and onChanges to use as props when mapping components?

This page summarizes the projects mentioned and recommended in the original post on /r/reactjs

Our great sponsors
  • SurveyJS - Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • primereact

    The Most Complete React UI Component Library

  • My first solution was to create a CustomColumn functional component which extends PrimeReact's column component. The CustomColumn component would contain the filterElement and its required state and functions. It would return a Column component with the applied filterElement prop. Unfortunately I later learned the DataTable can not accept any component except for Column components. It will not accept a react functional component which extends the original Column Component. Here is the github issue which states this is not possible: https://github.com/primefaces/primereact/issues/644#issuecomment-790648272

  • SurveyJS

    Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.

    SurveyJS logo
NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts