This is a simple enough question.
After taking a look at the documentation for ion-pane it states:
A simple container that fits content, with no side effects. Adds the ‘pane’ class to the element.
What does it mean when it states "no side effects"? What are the use cases for ion-pane?
Ionic Framework provides several different layouts that can be used to structure an app. From single page layouts, to split pane views and modals.
The Ionic Page handles registering and displaying specific pages based on URLs. It's used underneath NavController so it will never have to be interacted with directly. When a new page is pushed with NavController , the URL is updated to match the path to this page.
Honestly, I never used ion-pane before, but this question intrigued me so I went searching. As it seems, and you can see on this Codepen: http://codepen.io/anon/pen/JGwJKv?editors=1010, if the content is too big (if you try to resize the browser window to very small) it will not show it. Opposed to the ion-content
which will add scroll bars and allow you to use ion-refresher
and some other options (tapping into scroll delegate, etc.).
So, to be honest, I never stumbled upon a need for such a use-case, so would probably never use ion-pane. The lacking documentation about it, kind of suggests the same...
I actually used it for the first time on an app where I had dynamic divs that needed to fill the screen without adding scroll bars. Switching from ion-content
to ion-pane
did the trick for me.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With