I have a Windows Phone 8 application, i am looking to see why my home page is loading very slowly.
My Home page has the following structure:
<PivotControl>
<PivotItem>
<LongListSelector/>
</PivotItem> Times 5
</PivotControl>
I have a total of 5 PivotItems each of these items has its own api call to get the items so that it can show them. Each Pivot Item at first loads 12 Elements and them loads more as the user starts scrolling.
My question is has anyone encountered this problem of having a heavy main page with lots of elements? and what improvements did you do so that the page can load faster. I have already reduced the number of elements that i show (before I was loading 40 elements in each PivotItem).
EDIT: My ListItemTemplate is pretty clean (i have cleaned it to make it lighter in XAMLcode) it has one Grid that em-globes and InvokeCommandAction, an image, a border and 3 TextBlocks
Edit2: I have gained about 30% in load time by Collapsing my different LongListSelector when the user is not on my PivotItem thus I am hiding 2 LongListSelector. I am showing the PivotItem that is on the right in the middle (of course) and on the left, when the user swipes left or right I reload and hide the necessary elements. Its not pretty but it helps.
EDIT3: Almost (90%) all of my styles are already placed in my StylePage and called to style my elements. I have found that adding a little animation when the user enters and leave the page, allows me have a better transition between the pages. Here is my classic transition code:
<toolkit:TransitionService.NavigationInTransition>
<toolkit:NavigationInTransition>
<toolkit:NavigationInTransition.Backward>
<toolkit:TurnstileTransition Mode="BackwardIn" />
</toolkit:NavigationInTransition.Backward>
<toolkit:NavigationInTransition.Forward>
<toolkit:TurnstileTransition Mode="ForwardIn" />
</toolkit:NavigationInTransition.Forward>
</toolkit:NavigationInTransition>
</toolkit:TransitionService.NavigationInTransition>
<toolkit:TransitionService.NavigationOutTransition>
<toolkit:NavigationOutTransition>
<toolkit:NavigationOutTransition.Backward>
<toolkit:TurnstileTransition Mode="BackwardOut" />
</toolkit:NavigationOutTransition.Backward>
<toolkit:NavigationOutTransition.Forward>
<toolkit:TurnstileTransition Mode="ForwardOut" />
</toolkit:NavigationOutTransition.Forward>
</toolkit:NavigationOutTransition>
</toolkit:TransitionService.NavigationOutTransition>