jQuery - Cannot get index of an element : I want to get the index of d-flex that is inside "#Equipmentsfield_wrapper" but it doesnt working.

I know that's wrong but i'm using this

    alert($(this).children('div').index());

        


    <div id="Equipmentsfield_wrapper">
            <div class="d-flex">
            <input type="text" class="form-control" name="equipments[]" value="" required/>
            <a href="javascript:void(0);" id="Equipmentsadd_button" class="fieldAddDeleteIcon" title="Add field"><i class="fa fa-plus"></i></a></div>
        
        <div class="d-flex">
            <input type="text" class="form-control" name="equipments[]" value="" required/>
            <a href="javascript:void(0);" id="Equipmentsadd_button" class="fieldAddDeleteIcon" title="Add field"><i class="fa fa-plus"></i></a></div>
        
        </div>