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

Add a bundle size budget for the widget to CI

Chiusa Adatta ai principianti
#176 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à
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
82/100
Tipo di issue
Funzionalità
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
github-actions, typescript

Direzione di ricerca

Inizia dal package.json nella root e dalle righe 35–42 di .github/workflows/ci.yml; CONTRIBUTING.md descrive la configurazione di pnpm e l’ordine di build. Aggiungi size-limit con @size-limit/file, configura i budget gzip per packages/widget/dist/chatcops.min.js e packages/widget/dist/chatcops.esm.js, aggiungi lo script size nella root ed eseguilo in CI dopo la build. Il lavoro è completato quando pnpm size segnala entrambi i file, CI verifica che la IIFE non superi 14 KB gzip e CONTRIBUTING.md menziona il budget.

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

Descrizione

enhancement good first issue hacktoberfest testing widget

The widget is about 12 KB gzipped today (packages/widget/dist/chatcops.min.js after pnpm -r build), but nothing stops it from growing. CI only builds, typechecks and tests (.github/workflows/ci.yml, lines 35 to 42).

What to do

  • Add size-limit with @size-limit/file as a root dev dependency.
  • Add a .size-limit.json with a 14 KB gzip limit for packages/widget/dist/chatcops.min.js and a separate entry for packages/widget/dist/chatcops.esm.js.
  • Add a size script to the root package.json and a CI step after the build that runs it.
  • No PR comment bot for now. A failing step is enough.

Acceptance criteria

  • pnpm size prints both files with their gzip size and passes on dev
  • CI fails when the IIFE goes over 14 KB gzip (show it by temporarily lowering the limit in your PR description, not in the committed config)
  • CONTRIBUTING.md mentions the budget in one line
  • No changeset needed (tooling only)

Want to work on this? Comment below and I'll assign it to you. Please take one issue at a time, branch off dev, and open your PR against dev with Closes #<this issue number>. Setup notes (pnpm, build before test) are in CONTRIBUTING.md.

Lingua principale
TypeScript
Stelle
13
Fork
7
Merge medio
3h 33m
PR unite (30g)
176

Preparare l'ambiente

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 codercops/chatcops

Tutte le issue di codercops/chatcops

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.