no matter if to repair or change your iPhone is a personal decision that depends on many aspects. think about the Expense, the severity of The problem, the age of your product, plus your environmental problems.
From https://www.todayposting.com/10-signs-your-iphone-needs-repair-asap-dont-ignore-these-red-flags/