サンプルの html コードは次のとおりです。
<div id="current_element">Current element</div>
Many unknown tags...
<div class="target">This is target element</div>
Many other tags...
Target 要素と現在の要素は同じ親の下にない可能性があるため、.nextAll('.target') で見つけることができないことに注意してください。
それを見つける簡単な方法はありますか?ありがとう!