A Republican-led bill to impose harsher sentences for people convicted of fentanyl-like drug crimes narrowly passed the House on Thursday evening, with 98 Democrats supporting the measure.