I am a huge fan of pesto, but when my daughter was very young, I was wary about using 'real' (pine-nut) pesto on her pasta. I also wasn't sure about the consistency (as it can be grainy).
There are many things that you can substitute in the place of pine nuts, but I just got rid of the pine nuts entirely.
"Real" pesto consists of basil, oil, Parmesan cheese, and pine nuts. What I do is use a small amount of basil (remove the stems), puree with a tiny bit of olive oil, and then add sour cream and a sprinkle of Parmesan cheese. I don't have an exact recipe, because I often make just enough for a single serving of pasta, or just enough to store maybe an extra "ice cube" size portion of it. It basically looks like a light green alfredo sauce and it tastes amazing! You can adjust the recipe to whatever consistency is good for your child, and pour right over pasta!