Threads Scroll Restoration Fix (Firefox)

Fix back button not restoring scroll position on threads.com in Firefox

Du musst eine Erweiterung wie Tampermonkey, Greasemonkey oder Violentmonkey installieren, um dieses Skript zu installieren.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

Sie müssten eine Skript Manager Erweiterung installieren damit sie dieses Skript installieren können

(Ich habe schon ein Skript Manager, Lass mich es installieren!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

Autor
Tsuyumi25
Installationen heute
0
Installationen gesamt
0
Bewertungen
0 0 0
Version
0.2
Erstellt am
10.05.2026
Letzte Aktualisierung
10.05.2026
Größe
2,65 KB
Lizenz
MIT
Wird angewandt auf

Threads Scroll Restoration Fix (Firefox)

On Firefox, pressing the back button after opening a post on threads.com often scrolls back to the top of the timeline instead of returning to where you left off. Chrome handles this correctly.

This script works around the issue by:

  • Setting scrollRestoration to manual and taking over scroll position tracking
  • Saving scroll position before each navigation via sessionStorage
  • Restoring scroll position after back navigation, waiting for content to render before scrolling
  • Blocking scrollTo(0, 0) calls during restoration to prevent Threads' own JS from overriding the fix

Disclaimer: This script was written by Claude (AI). It is not verified or guaranteed to work in all cases, but it has been working fine for personal use so far.


Threads 滾動位置修復(Firefox)

在 Firefox 上,於 threads.com 點進貼文後按上一頁,時間線經常會跳回頂部,而不是回到剛才的位置。Chrome 沒有這個問題。

這個腳本的做法:

  • 把 scrollRestoration 設為 manual,自行接管滾動位置追蹤
  • 每次導航前將滾動位置存進 sessionStorage
  • 返回時等頁面內容 render 完再恢復滾動位置
  • 在恢復期間擋掉 scrollTo(0, 0) 呼叫,防止 Threads 自身的 JS 蓋掉修復

聲明: 本腳本由 Claude(AI)撰寫,未經全面驗證,不保證在所有情境下都能正常運作,但我目前自用沒有遇到問題。