guardian / guardian/dotcom-rendering

DCAR: Toggle Display Of Ad Placeholders In Development

Open
#10,170 1 comment 0 reactions 1 assignee Claimed by @frederickobrien View on GitHub
Interactives :chart_with_upwards_trend: maintenance Pick me up Team Candidate: WebX
Dominant language
TypeScript
Stars
274
Forks
34
Avg merge
2d 22h
Merged PRs (30d)
121

Description

By default we don't show the ad placeholders that are used to insert ads; we only display them if we're able to check with the native layer that the user is not premium.

https://github.com/guardian/dotcom-rendering/blob/89015504a3457c41d5acda25c754d1e95f9a5366/dotcom-rendering/src/components/AdPortals.importable.tsx#L130-L155

As a result, when viewing DCAR in a browser for development purposes you will never see the ad placeholders, because there is no native layer to query.

However, sometimes it's useful to be able to see these placeholders outside of the app. For example, when interactive developers (Design, Visuals) are building interactives they would like to be able to see them, to make sure they can work around them correctly.

We discussed coming up with a mechanism for toggling the placeholders on and off for development purposes, possibly with a query parameter. Ideally this parameter would work in preview.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.