The purpose of God in creating you reaches its ultimate end in your heart. Namely, in the treasuring in your heart of God — the treasuring of God above all things with white-hot affection. And the mind is given to serve that act through the right apprehensions of reality.
“Doctrine exists for the sake of delight.”
If you apprehended reality for what it really is, your heart would be ignited with a white-hot affection for the supreme reality: God himself. Or to put it several other ways, right thinking about God exists for the sake of right feelings for God — in that order. Logic exists for the sake of love. Reasoning exists for the sake of rejoicing. Doctrine exists for the sake of delight. Reflection about God exists for affection for God. The head is meant to serve the heart. Knowing the truth is the basis of admiring the truth.
Both thinking and feeling are essential. They are not coordinate. Rather, thinking serves affection. The devil has many factually true thoughts, and none of them rightly serves his heart and brings him to love the truth. Therefore, his right thinking is no good. I don’t care how right it is or how factual it is. It aborts. It fails. It doesn’t reach the ultimate goal of people created in God’s image: that the heart would explode with white-hot affection for him. That’s why we’re made. The mind, when it’s rightly serving the heart, brings that forward.
Source: John Piper | Desiring God