Closed pke closed 10 months ago
I'd even add that paragraphs should not have a top margin at all. In my opinion, every block (as opposed to inline) components should have a bottom margin.
That way, every block handles the margin/separation with the next block, not the previous one. The absence of a previous block (i.e. only one block, or the first block in the hierarchy) would not change the way the current block is laid out.
I have to agree. In my layout library
Since margins do not collapse in RN like they do in web CSS its often introducing little bugs when paragraphs have a
marginTop
of 10 by default. Especially if there is only one paragraph in the rendered hierarchy at that level. In that case no top margin should be applied (like it would in web CSS).