How to properly add text content with padding on the page?
-
Hello. The app i’m trying to develop mostly contain long text and paragraph. When adding text to the <ons-page>, the text doesn’t have any padding on left and right side. I also tried using <div class=“content”> but the result is the same. is there a proper way to have this? of should I use/add my own css style?
-
There’s no padding by default, so you basically need to style text like you would with regular HTML elements.
See here for some examples of how to do that: https://onsen.io/playground/?framework=vanilla&category=reference&module=input
Also check the User Interface Tutorials section (at the bottom of the drop-down menu) for some more complicated UI examples.
-
@emccorson Got it! Thank you!