Are non-Apple iPhone chargers safe?
Most of the third party iPhone ones are mostly safe most of the time. However there isn't a good way to tell which ones aren't. Here is a teardown of an Apple one and a clone.
I say most of the time since some of the safety issues are only problems if there are faults. But in a poorly designed one, faults can cause fire and/or shock. Also poorly designed ones can get hot, which might be a problem in an enclosed space.
I personally would avoid anything that claims to be from Apple but is priced lower than theirs. That demonstrates the seller is willing to lie, so they are questionable to begin with. A reputable seller wouldn't try to pretend they are selling Apple chargers.
Your mileage may vary. Most 3rd-party accessories use inferior parts or less rigorous quality assurance. They may work, they may not.
Paying the extra $10 for the official Apple charger is probably worth it, when weighed against the risk of buying a new iPhone.
Plus, any issues with official accessories will be covered by the warranty.
Basically, it's hit or miss. Use at your own risk.