Detect if screen is locked?

Android/iOS/

Is it possible to detect if the screen is locked whilst the app is in the background?

I don’t know of a way to detect if the screen is locked or not, but you can detect if your app is backgrounded or foregrounded - https://reactnative.dev/docs/appstate