Sunless Sea is a good example to look at because it’s widely considered IF in this community (I think) but labelled an RPG on other sites (including Wikipedia). I haven’t played it, but it obviously has both exploration/combat/levelling and interaction with the text.
I’d consider it a hybrid of genres and I’m happy to put any genre tag on anything.
I’d even say that many RPGs have elements of interactive fiction, such as dialogue branching, a choice of who to talk to, and, sometimes, direct influence over story events.
It’s just a question of when something’s such a small part of the game that you wouldn’t recommend it to someone on those grounds.