Matthew 22:40 On these two commandments hang all the law and the prophets.
What Christ said actually endorses the law and the prophets in their entirety. He is claiming the two great commandments are the root out of which all the law and the prophets grow, they are the nail by which the everything else is suspended. That is very different than dismissing any portion of the law or prophets in favor of the great two commandments.
This difference is important, as it has become common for some to use Christ's statement about the two great commandments in an attempt to supplant the prophets. The idea seems to be that one can interpret the great two commandments as one sees fit, then use that interpretation to summarily dismiss what modern and ancient prophets have said on a matter .
But Christ doesn't state that one can supplant the law and the prophets with the great two commandments. Instead Christ states that the law and the prophets are exactly the tree of truths that really do hang from the great two commandments when they are properly understood.
Want to know what loving God with all one's might, mind and strength looks like in practice? Want to know what loving one's neighbor as one's self in a way secondary to the first commandment looks like in practice?
Then read the scriptures, and listen to the counsel and commandments of prophets both ancient and modern.
Doing so you will find that a critical part of what it looks like is keeping commandments. Which is no surprise, as the way God measures our love of him is quite different than what we might expect:
John 14:21 He that hath my commandments, and keepeth them, he it is that loveth me: and he that loveth me shall be loved of my Father, and I will love him, and will manifest myself to him.
If that is really correct, whether we love God with all our heart, might, mind, and strength is not measured by words alone, but by whether we keep his commandments with all our heart, might, mind and strength. The first great commandment is to love God, and the way he stated that he measures our love is by our obedience to him.
This truth is seen even in the life of our great examplar, Jesus Christ. He submitted his own will completely to the will of his Father. In so doing he showed that he really did love his Father far more than he loved himself. Thus Christ's perfect obedience was the godly proof of Christ's perfect love for his Father.
And it is the same for us. It is easy to talk about loving God. But to pay the price of submitting our wills to his will is the true demonstration of real life affection for and trust in him as our loving Father.