In AEM sightly check author or preview or publish instnace
We have a requirement to load an experience fragment in aem author instance (in all modes - edit, preview & disabled) using data-sly-resource approach where as in aem preview & publisher instances we want to load the experience fragment using Server Side Include (SSI) approach.
To achieve this I need to identify in the AEM Instance (author, preview or publish) in AEM Sightly Code using data-sly-test approach.
Please suggest me how to implement it.