danish1658 / react-native-dropdown-select-list

☝️ React Native Select List Equivalent to Html's Select with options"
https://www.npmjs.com/package/react-native-dropdown-select-list
MIT License
193 stars 90 forks source link

ERROR Error: Objects are not valid as a React child (found: object with keys {id, skillName}). If you meant to render a collection of children, use an array instead. #77

Closed pradhyumansinh9849 closed 1 year ago

pradhyumansinh9849 commented 1 year ago

ERROR Error: Objects are not valid as a React child (found: object with keys {id, skillName}). If you meant to render a collection of children, use an array instead.

pradhyumansinh9849 commented 1 year ago
  let newArray = response.data.data.map((item) => {
      return {key: item.id, value: item.skillName}
    })
    setAPIDataSkils(newArray);
pradhyumansinh9849 commented 1 year ago
  let newArray = response.data.data.map((item) => {
      return {key: item.id, value: item.skillName}
    })
    setAPIDataSkils(newArray);