Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

consider creating separate hugo pages for each important url

Aperta
#790 2 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 7 giorni

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
20/100
Tipo di issue
Refactoring
Chiarezza
Da chiarire
Stato di attività
Ferma
Stack tecnologico
hugo, javascript

Direzione di ricerca

Inizia leggendo netlify.toml, app/facade.js e services/nginx/conf.d/shift.conf per confrontare le mappature degli URL di produzione e sviluppo. Poi esamina i contenuti di addevent.md, calendar.md e pedalpalooza e i layout di caledit/calevents insieme ai template di base di Hugo e alla documentazione degli shortcode; il lavoro è completato quando la struttura scelta separa i tipi di URL importanti senza lasciare che le tre mappature non siano sincronizzate.

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

Descrizione

frontend question

In talking through the hugo url handling at the biking and bits ride with Steven and Melanie -- i think it might be good to detangle the page handling some. ( noting that this would be a relatively big change. )

currently, production splats down[^1] what should be multiple pages into single page(s):

  1. all https://shift2bikes.org/addevent/... urls are handled by addevent.md which uses the caledit layout.
  2. all https://shift2bikes.org/calendar/... urls are handled by calendar.md which uses the calevents layout

what might be better is something like:

  • newEvent.md: for shift2bikes.org/addevent/
  • editEvent.md: for shift2bikes.org/addevent/edit-<event_id>-
  • calList.md: for shift2bikes.org/calendar/
  • calDaily.md: for shift2bikes.org/calendar/ event-<daily_id>

each pointing to a unique layout. similarly, the pedalpalooza page ( +/- the archive pages ) could point to pedalpalooza-calendar.md as they do currently; but that markdown could use a specialized pedalpalooza layout instead of calevents.


probably first it'd be worth investigating base templates. much of the various layout .html is duplicated, and introducing new layouts would only make that worse. ( base templates would allow better sharing )

or, as an alternative to adding a layout per .md file, it might be possible to create custom shortcodes so the .md files can directly indicate how the page should look. ( right now the .md files are empty except for the layout type: name )


[^1]: the production mapping is in netlify.toml: https://github.com/shift-org/shift-docs/blob/87980dcf72c81a9679b79432a43ad1ce03d1596e/netlify.toml#L137 -- unfortunately, netlify.toml isn't used in development mod. so its behavior is duplicated for 'npm run dev' byapp/facade.js and in services/nginx/conf.d/shift.conf for docker dev ( under the section 'development endpoints'. ) all three spots would have to be updated to stay in sync.

Lingua principale
JavaScript
Stelle
30
Fork
26
Merge medio
6g 23h
PR unite (30g)
3

Preparare l'ambiente

  • Include un Dockerfile o un file Docker Compose
  • Nessun modello di pull request
  • Nessuna guida per i contributori

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 shift-org/shift-docs

Tutte le issue di shift-org/shift-docs

Issue simili

Altre issue su JavaScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.