You can follow these steps:
Step 1: Go to the Settings app on your OnePlus.
Step 2: Type "Notification History" in the search bar. This should open the Notification History section. It's pretty much that.
Step 3: To enable it, go to the Setting, and it will allow it.