I need to retrieve the value of index from .map()

```
class ImageSliderScreen extends StatefulWidget {
  final List<RecipeStepsModel>? recipeStepsList;
  ImageSliderScreen({required this.recipeStepsList});
  @override
  _ImageSliderScreenState createState() => _ImageSliderScreenState();

}

```

I have a list of `RecipeStepsModel` and I need to build a image carousel out of it:

```
      Container(
        child: CarouselSlider(
          options: CarouselOptions(height: 400.0),
          items: widget.recipeStepsList!.map(
            (i) {
              return Builder(
                builder: (BuildContext context) {
                  return Container(
                    width: MediaQuery.of(context).size.width,
                    margin: EdgeInsets.symmetric(horizontal: 5.0),
                    child: ImageCarouselCard(
                      recipeSteps: widget.recipeStepsList![i], //error
                    ),
                  );
                },
              );
            },
          ).toList(),
        ),
      ),

```

I'm getting this error: `The argument type 'RecipeStepsModel' can't be assigned to the parameter type 'int'`

What am I missing here? how can I get the index of my `recipeStepsList`?