Hiding AMP element in “Transitional” mode
-
Hi!
I am currently trying AMP on my website in “Transitional Mode”. I followed amp-user-notification documentation to create simple cookie notice bar at the bottom. It’s simple and it works just fine, here’s the code
<amp-user-notification
layout=”nodisplay”
id=”amp-user-notification1″
>
This website uses cookies.
Learn more about your privacy.
<button on=”tap:amp-user-notification1.dismiss”>Got it!</button>
</amp-user-notification>I inserted it into footer. The problem is that this notice bar is also visible on non-AMP webpages.
I managed to hide it via “Ad inserter” plugin which has a feature to separate non-AMP and AMP codes. But I would welcome more elegant and “native” solution, if there’s any.
Sorry if I am asking in wrong place.
Thanks.
- The topic ‘Hiding AMP element in “Transitional” mode’ is closed to new replies.