How can I tell from code if i'm looking at a page in Experience Manager


I would like to be able to tell from code (from a component’s class in java) whether the user is looking at it in Experience Manager (edit mode) or from the front end of the website. I presume there is a method somewhere I can call that will return true/false to tell this?



documented here:

1 Like

Perfect, exactly what I was looking for thanks. Marking as solution.