Skip to content

Conversation

fabienheureux
Copy link
Member

@fabienheureux fabienheureux commented Aug 28, 2025

Description succincte du problème résolu

Cf https://www.notion.so/accelerateur-transition-ecologique-ademe/SEO-Ajouter-un-backlink-au-niveau-des-iFrames-2326523d57d780d09411e91b9eb60c8f?source=copy_link

🗺️ contexte: SEO

💡 quoi: Ajout d'un backlink sur les iframes

🎯 pourquoi: Pour améliorer le SEO des intégrations par iframe

🤔 comment:

  • à la génération de l'iframe, on ajoute un backlink en dessous de l'iframe
  • le contenu doit etre contribuable de manière centralisée

Dans l'admin wagtail

  • ajout de champs permettant de contribuer les backlinks

En front

  • on fetch le contenu de chaque backlink à partir d'une clé unique
  • on l'ajoute dynamiquement au site qui nous embarque

Exemple résultats / UI / Data

image

Auto-review

Les trucs à faire avant de demander une review :

  • J'ai bien relu mon code
  • La CI passe bien
  • En cas d'ajout de variable d'environnement, j'ai bien mis à jour le .env.template
  • J'ai ajouté des tests qui couvrent le nouveau code

✅ Reste à faire (PR en cours)

📆 A faire (prochaine PR)

@fabienheureux fabienheureux force-pushed the add-backlink-on-iframes branch from 8149ae2 to ecff44a Compare September 1, 2025 08:31
@fabienheureux fabienheureux force-pushed the add-backlink-on-iframes branch from ecff44a to f6d983d Compare September 1, 2025 08:42
@fabienheureux fabienheureux marked this pull request as ready for review September 11, 2025 14:56
Copy link
Contributor

@kolok kolok left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Qu'il en soit ainsi :)

core/views.py Outdated
from qfdmd.models import EmbedSettings


@cache_control(max_age=31536000)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
@cache_control(max_age=31536000)
A_YEAR = 31536000
@cache_control(max_age=A_YEAR)

?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tu es sur de vouloir le cacher pendant 1 an ?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

j'ai abaissé à 10mn, en vrai c'est un peu du zêle, je veux juste pas que ca nous explose à la figure car du coup on fait 2 requetes au serveur au lieu d'une pour chaque iframe désormais

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

J'ai rajouté l'info dans l'admin

Image

@fabienheureux fabienheureux assigned kolok and unassigned fabienheureux Sep 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants