Skip to content

Latest commit

 

History

History
46 lines (35 loc) · 1.66 KB

File metadata and controls

46 lines (35 loc) · 1.66 KB

Contributing

Thanks for taking a look. This is a small, dependency-free project, so contributing is deliberately low-ceremony.

Getting set up

git clone https://github.com/css-scroll-driven/scroll-timeline-builder.git
cd scroll-timeline-builder
npx serve .          # or: python3 -m http.server 8000

There is no build step and nothing to install. Node is needed only for tests:

node --test

Ground rules

  • No dependencies, no build step, no framework. Plain HTML, CSS and ES modules. A pull request that adds a package.json dependency will not be merged.
  • Keep src/codegen.js pure. It must never touch the DOM — that is what lets the test suite exercise the real generator under node --test.
  • Test anything that changes generated output. Add a case to tests/codegen.test.mjs; several tests assert whole stylesheet strings so that formatting changes are visible rather than silent.
  • Route state changes through store.patch() so every view stays in sync.
  • New state fields need a default in defaultState(), validation in sanitizeState(), and a mapping in serialize.js, or they will not survive a permalink.
  • Match the surrounding style: two-space indent, single quotes, semicolons, and comments that explain why rather than restating the code.

Pull requests

Keep them focused, describe what changed and why, and make sure node --test passes. If you are adding a preset, include a line about what it demonstrates that the existing six do not.

Bug reports

A permalink from the app is the fastest possible repro — it encodes the exact configuration. Include it along with your browser and version.