Check out example codes for "css selector every child except last". It will help you in understanding the concepts better.

Code Example 1

:not(:last-child)

Learn ReactJs, React Native from akashmittal.com