So I was reading my book and it listed this piece of code. The first piece of code is in the book and the 2nd is just my test on the piece of code. I am curious as to why in the functions parameters there is a reference to aString.
I've noticed that removing it has no affect on the outcome of the code.
I think you mean removing the reference, not the parameter.
Objects which are of a type of class are usually passed by reference because they could be arbitrarily large, we want to avoid copying the whole thing. This is the concept of pass by reference versus pass by value (copy)
References are just like pointers, except that references must refer to an object, unlike pointers which can be made to point at anything (maybe garbage) including nullptr.