suggestion: replace usage of `router.replace` with `router.push` in various places

Aperta
#8,258 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
typescript
Ambito
frontend, web-dev

Direzione di ricerca

Start with packages/ui/src/layouts/shared/browse-tab/composables/use-browse-search.ts, especially the router.replace call around line 405. The issue describes browser back and forward navigation problems and names Discover tab changes as another example, but the other affected locations are not listed. Find where replacement is used for navigation state and check that switching tabs and search preserve the expected history; done means browser navigation no longer loses the prior tab or search state.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

website

the modrinth website seems to prefer replacing the history state over pushing a new one, which is not standard and breaks browser forward/back navigation, which a portion users would describe as an inconvenience.

one such example of broken functionality is described in https://github.com/modrinth/code/issues/1843, but simpler stuff such as going between tabs in "Discover" (Mods, Shaders, etc.) can overwrite the history state, resulting in losing your place in the previous tab

i will be submitting a pull request to address this issue, starting with the browse search component: https://github.com/modrinth/code/blob/f73010ae0809813120a16b733a3d0bfd23f76e24/packages/ui/src/layouts/shared/browse-tab/composables/use-browse-search.ts#L405

Lingua principale
Rust
Stelle
2.5k
Fork
663
Merge medio
2g 11h
PR unite (30g)
122

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di modrinth/code

Tutte le issue di modrinth/code

Issue simili

Altre issue su Rust

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.