My observations about Sanderson books are that pretty much everything in them happens for a reason. Sometimes though you don't know the real reason until the end of the book or even the next one. As for the Shallan flashbacks - She deals with her problems by avoiding them and pretending they are not there. By covering herself with lies. By pretending to be someone else. Although I agree that this is visible more clearly after you read Oathbringer and how she deals with problems.