Skip to content

Instantly share code, notes, and snippets.

@gwennguihal
Last active February 22, 2019 07:35
Show Gist options
  • Save gwennguihal/c09962c33b643715a6c3edbd81c1d780 to your computer and use it in GitHub Desktop.
Save gwennguihal/c09962c33b643715a6c3edbd81c1d780 to your computer and use it in GitHub Desktop.
//--- SectionDescriptor
// new propertie
private(set) var verticalSpaces = [Int: VerticalSpace]()
@discardableResult public func reloadSection(_ builderClosure: @escaping BuilderClosure) -> SectionDescriptor {
let builder = Builder(sectionDescriptor: self)
builderClosure(builder)
verticalSpaces = builder.verticalSpaces
return reloadSection { cells in
cells = builder.cells
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment