Swiftpack.co - FluidGroup/ResultBuilderKit as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by FluidGroup.
FluidGroup/ResultBuilderKit 1.3.0
Set of result builder
⭐️ 9
🕓 1 year ago
.package(url: "https://github.com/FluidGroup/ResultBuilderKit.git", from: "1.3.0")

ResultBuilderKit

a set of result-builder

Please open PR if you have nice builder.

ArrayBuilder

To create an array from blocks and expressions

let array: [MyElement] = buildArray {
  
  constants
  
  if flag {
    option
  }
  
  additionalElement
  
}

or


func doSomething(@ArrayBuilder<String> _ value: () -> [String]) {
  let array: [String] = value()
  ...
}

GitHub

link
Stars: 9
Last commit: 1 year ago
Advertisement: IndiePitcher.com - Cold Email Software for Startups

Release Notes

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics