Sourcery is a code generator for Swift language, built on top of Apple's own SwiftSyntax. It extends the language abstractions to allow you to generate boilerplate code automatically. It's used in over 40,000 projects on both iOS and macOS and it powers some of the most popular and critically-acclaimed apps you have used (including Airbnb, Bumble, New York Times). Its massive community adoption was one of the factors that pushed Apple to implement derived Equality and automatic Codable conformance. Sourcery is maintained by a growing community of contributors. Try Sourcery for your next project or add it to an existing one, you'll save a lot of time and be happy you did! Sourcery allows you to get rid of repetitive code and create better architecture and developer workflows. An example might be implementing Mocks for all your protocols, without Sourcery you will need to write hundreds lines of code per each protocol.
Features
- Sourcery is a command line tool
- Sourcery removes the need to write any of the mocks code
- Sourcery will also make every single mock consistent
- Sourcery can be applied to arbitrary problems across your codebase
- It extends the language abstractions to allow you to generate boilerplate code automatically
- It's used in over 40,000 projects on both iOS and macOS