ios - Wanna use StoryBoard as tab of child viewcontrollers XLPagerTabStrip -


i posted project's github issue, https://github.com/xmartlabs/xlpagertabstrip/issues/270

https://github.com/xmartlabs/xlpagertabstrip

plz check method: override func viewcontrollers(for pagertabstripcontroller: pagertabstripviewcontroller) -> [uiviewcontroller]

this methods return uiviewcontroller show tab's viewcontrollers, can render, , library example shows how put programatically not storyboard

var child_1 : homeviewcontroller{     let storyboard = uistoryboard(name: "main", bundle: nil)     let child_1 = storyboard.instantiateviewcontroller(withidentifier: string(describing: "homeviewcontroller")) as! homeviewcontroller     child_1.iteminfo = "home"     return child_1 }   override func viewcontrollers(for pagertabstripcontroller: pagertabstripviewcontroller) -> [uiviewcontroller] {      let child_2 = tablechildexampleviewcontroller(style: .plain, iteminfo: "beef")     let array :  [uiviewcontroller] = [child_1, child_2]     return array } 

for child_1 , wrote code this, doest work (try use storyboard) child_2, works fine thats programatically.

this code's problems tha, when instantite instance, cannot init "child_1.iteminfo"

plz give me advice


Comments

Popular posts from this blog

php - How to display all orders for a single product showing the most recent first? Woocommerce -

asp.net - How to correctly use QUERY_STRING in ISAPI rewrite? -

angularjs - How restrict admin panel using in backend laravel and admin panel on angular? -