list/list.go
func (l *List) Index() int {
	selected := l.scope[l.cursor]

	for i, item := range l.items {
		if item == selected {
			return i
		}
	}

	return NotFound
}
func (l *List) Index() int {
	selected := l.scope[l.cursor]

	for i, item := range l.items {
		if item == selected {
			return i
		}
	}

	return NotFound
}
// Index returns the index of the item currently selected inside the searched list. If no item is selected,
// the NotFound (-1) index is returned.