AWS Open Source Blog

Style Dictionary + Hacktoberfest

中文版

The maintainers of Style Dictionary participated in Hacktoberfest this year for the first time, and it was a truly amazing experience. While our numbers don’t seem large, it has been terrific to get new contributors involved in the project and kick-start a lot of work that was in our backlog. One of the biggest benefits from participating in this event was getting many fresh eyes on the project, which allowed us to see what parts of the project and documentation were confusing or lacking. It also opened us up to new contributors and users whom we would not have otherwise found. That is especially useful for smaller projects that don’t yet have a big community.

Here are a few lessons we took away for next year:

  1. Be more prepared. We jumped on the Hacktoberfest train right when it started, but we did not have a groomed issue list to pull from for good first issues, which hindered us a bit. Next year we will start preparing the issue list in September.
  2. Set aside time every day. Even with our relatively small volume, it was helpful to spend 30 minutes to an hour at the beginning of each day to go over new pull requests or issues.
  3. Clean up branches. We had some issues where we had to change the branches of pull requests and got into some merge conflicts with longer-running branches. By next year we hope to have a better branching strategy that will include CI/CD to release new versions.
  4. Be very clear and have examples. The issues that had the most success were ones that included very clear examples. Because you can’t expect newcomers to know the inner workings or philosophy behind a project, it is very helpful if you can point to an example or have very clear instructions.

Overview of Activity During Hacktoberfest

  • Pull Requests Opened: 27
  • Pull Requests Closed: 24
  • Issues Opened: 21
  • Issues Closed: 21 (the same number as issued opened is coincidence)
  • Contributors: 8

What We Accomplished

  • Started development on the next major release of Style Dictionary, 3.0
    • Bringing our code up-to-date with prettier, updated eslint, and ES6 syntax
  • Upgraded our testing by migrating to Jest and adding snapshot testing for files generated by Style Dictionary
    • Went from 191 tests to 226 tests and 29 snapshots
  • Added new built in formats
  • Added JSON5 support
  • Added configuration for templates and formats to not include the generated comment with build date
  • Fixed a few styling bugs with the documentation site
  • Fixed a bug with circular references
  • Improved our error messaging and console output a lot. Rather than stop at one reference error, collect all the errors and show them at once so you don’t have to fix one error, rebuild, repeat.
  • Began deprecation path of templates. No power is being removed, you can still use templates in a format. It was confusing to people that we had both templates and formats, so this change simplifies the API without removing any features.

Thank you to all the contributors for all your hard work! We will use this momentum to continue working on Style Dictionary, and we’e looking forward to Hacktoberfest next year.

Danny Banks

Danny Banks

Danny is a Sr. UX Designer at Amazon where he oversees UX design and research for the Seller Mobile app. In his role at Amazon, Danny also developed, and continues to maintain, the open source Style Dictionary framework, which organizes cross-platform style and design information.

Charles Dorner

Charles Dorner

Charles is a Sr. Design Technologist at Amazon where he strategizes concept planning 3-5 years into the future. In his role at Amazon, Charles also helped develop (and continues to maintain) the open source Style Dictionary framework, which organizes cross-platform style and design information.