TS - how to extract type from Picked array

I have the following type:

type ChallengeInput = {
  title: string,
  sections: Array<{
    title: string;
    description: string;
    videoId: string;
    collectionId: string;
    libraryId: number;
  }>;
};


And I want to get the type of a Section.

type Section = Pick<ChallengeInput, "sections">[number]


However this throws an error has no matching index signature for type number...

Any suggestions?
Was this page helpful?