From adfa765c4ede57224d126e355cccbc0447fc4bb1 Mon Sep 17 00:00:00 2001 From: pandaman Date: Mon, 28 Jun 2021 10:35:20 +0900 Subject: [PATCH] Add PRTemplate --- .github/PULL_REQUEST_TEMPLATE.md | 34 ++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index e69de29b..010f4821 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -0,0 +1,34 @@ +I changed to use ContiguousArray< UIViewController > type to store UIViewControllers in a contiguous block of memory. + + When using a large number of UIViewControllers as tabs, I think that using ContiguousArray will yield more predictable performance compared to Array. + + + +The changed files are: + +- Sources/PagerTabStripViewController.swift + +for Example: + +- BarExampleViewController.swift +- ButtonBarExampleViewController.swift +- InstagramExampleViewController.swift +- NavButtonBarExampleViewController.swift +- SegmentedExampleViewController.swift +- SpotifyExampleViewController.swift +- TwitterExampleViewController.swift +- YoutubeExampleViewController.swift +- YoutubeWithLabelExampleViewController.swift + + + +References + +- https://github.com/apple/swift/blob/main/docs/Arrays.rst + +- https://developer.apple.com/documentation/swift/contiguousarray + +- https://github.com/apple/swift/blob/main/docs/OptimizationTips.rst#advice-use-contiguousarray-with-reference-types-when-nsarray-bridging-is-unnecessary + +- http://jordansmith.io/on-performant-arrays-in-swift/ +- https://medium.com/@nitingeorge_39047/swift-array-vs-contiguousarray-a6153098a5 \ No newline at end of file