I am passing a prop in my component 

```
<ReactFoldableTableAllExams patientId={this.state.patientId}/>

```

I need to receive my prop in const, and I didn't find a way to solve my problem. I need my props in the function `StudyService.FindPastStudiesByPatientId`

```
const requestData = async (pageSize, page, sorted, filtered) => {
  console.log("Fetch data: sorted -> ", JSON.stringify(sorted));
  console.log("Fetch data: sorted -> ", JSON.stringify(pageSize));
  var data = await StudyService.FindPastStudiesByPatientId({

    take : pageSize,
    skip :page*pageSize,
    orderBy : sorted[0]? sorted[0].id:null,
    orderAsc : sorted[0]? !sorted[0].desc:null

  })

  return {
    rows : data.data,
    pages : 1
  }
}

export default class Example extends React.Component {
  state = {
    idStudy: 0,
    study :{},
    searchStudies :  {},
    patientId:0
  };

   fetchData(state, instance) {

    this.setState({ loading: true });

    // Request the data however you want.  Here, we'll use our mocked service we created earlier
    requestData(state.pageSize, state.page, state.sorted, state.filtered).then(
      res => {
        // Now just get the rows of data to your React Table (and update anything else like total pages or loading)

        this.setState({
          data: res.rows,
          pages: res.pages,
          loading: false
        });
      }
    );
  }
  constructor(props) {
    super(props);
    this.state = {
      study : {patient :{},prescriber:{},site:{}},
        data: [],
        pages: null,
        loading: true,
        sorted: [],
        patientId:this.props.patientId
      };
      this.fetchData = this.fetchData.bind(this);
  }

  render() {
    return (
      <div>      
        <ReactTable
          manual 
          data={data}
          pages={pages} 
          loading={loading} 
          onFetchData={this.fetchData} 
          columns={[
            {
              Header: "Information examen",
              columns: [
                {
                  Header: "Date examen",
                  accessor: "realizedDate",
                  Cell : dateCell,
                }
              ]
            }
          ]}
          defaultPageSize={20}

          className="-striped -highlight"
        />
      </div>
      </div>
    );
  }
}

```