Fix carbon ads and nuxt target 'static'

Offen
#439 2 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

Bewertung

Schwierigkeit
3/5
Geschätzter Aufwand
1-2 Tage
Anfängerfreundlichkeit
35/100
Issue-Typ
Bug
Klarheit
Größtenteils klar
Aktivitätsstatus
Veraltet
Tech-Stack
nuxt
Bereich
frontend

Rechercherichtung

Beginne mit nuxt.config.js und dem im Bericht erwähnten mounted-Lifecycle und vergleiche dann das Verhalten des statischen Builds mit der aktuellen Konfiguration nach #438. Fertig ist es, wenn die generierte Website das Carbon ads-Skript im DOM enthält und die Anzeigen bei Verwendung von target: 'static' angezeigt werden.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

bug
Support plan
  • is this issue currently blocking your project? (yes/no):
  • is this issue affecting a production system? (yes/no):
Context
  • node version:
  • module version with issue:
  • last module version without issue:
  • environment (e.g. node, browser, native):
  • used with (e.g. hapi application, another framework, standalone, ...):
  • any other relevant information:
What are you trying to achieve or the steps to reproduce?
const some = 'properly formatted code example';
What was the result you got?

When building the website using target: 'static' in nuxt.config.js the carbon ads script tag is not added to the DOM hence ads are not showing up.

What result did you expect?

Ads should be displayed. We've removed the target: 'static' for now (#438)

Perhaps the problem comes from the mounted lifecycle which is not triggered when generating the website statically.

Vorherrschende Sprache
Vue
Sterne
55
Forks
72
Ø Merge
4 Min.
Gemergte PRs (30 T.)
2

Entwicklungsumgebung

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus hapijs/hapi.dev

Alle Issues in hapijs/hapi.dev

Ähnliche Issues

Weitere Issues zu Web Dev

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.