In order for anyone to properly explain this, we would first need to know exactly what you're referring to in relation to "the law".
In scripture, there are at least four different things which are called "the law".
For example:
Mark chapter 10
[2] And the Pharisees came to him, and asked him, Is it lawful for a man to put away his wife? tempting him.
[3] And he answered and said unto them, What did Moses command you?
[4] And they said, Moses suffered to write a bill of divorcement, and to put her away.
[5] And Jesus answered and said unto them, For the hardness of your heart he wrote you this precept.
[6] But from the beginning of the creation God made them male and female.
[7] For this cause shall a man leave his father and mother, and cleave to his wife;
[8] And they twain shall be one flesh: so then they are no more twain, but one flesh.
[9] What therefore God hath joined together, let not man put asunder.
In verse 4, the Pharisees quoted "the law" of Moses from Deuteronomy chapter 24.
The word "Deuteronomy" literally means "second law" or the second giving of "the law" that Moses received on Mt. Sinai.
However, while quoting from "the law" of Moses himself, Jesus cited Genesis 1:27 or Genesis 5:2 (vs. 6) and Genesis 2:24 (vs. 7), and these things happened at least 2500 years BEFORE Moses was given "the law" or the 10 Commandments on Mt. Sinai.
We see how "the law" can apply to this same PRE-MT. SINAI timeframe more clearly here:
"Let your women keep silence in the churches: for it is not permitted unto them to speak; but they are commanded to be under obedience, as also saith the law." (I Cor. 14:34)
Here, Paul, while alluding to what was written in Genesis 3:16, called it "the law", and, again, this event transpired at least 2500 years before Moses received "the law" or the 10 Commandments on Mt. Sinai.
Then we have this to consider:
"And he said unto them, These are the words which I spake unto you, while I was yet with you, that all things must be fulfilled, which were written in the law of Moses, and in the prophets, and in the psalms, concerning me." (Luke 24:44)
Here, Jesus clearly made a distinction between "the law of Moses", "the prophets" and "the psalms", yet, elsewhere in scripture, both the psalms and the prophets are called "the law".
For example, while citing Psalm 82:6, Jesus called it "the law":
"Jesus answered them, Is it not written in your law, I said, Ye are gods?" (John 10:34)
Again, while citing what was written by the prophet in Isaiah 28:11-12, the Apostle Paul called it "the law":
"In the law it is written, With men of other tongues and other lips will I speak unto this people; and yet for all that will they not hear me, saith the Lord." (I Cor. 14:21)
With these truths before us, when you refer to "the law", what, exactly, are you referring to?
Amen thorough and informative stuff
also there’s Moses law refered to as the “book of the law “
this book of the law had a specific intent at the end of Moses life after God had looked and observed and tried the children of Israel for a time in the wilderness
“And the Lord appeared in the tabernacle in a pillar of a cloud: and the pillar of the cloud stood over the door of the tabernacle. And the Lord said unto Moses, Behold, thou shalt sleep with thy fathers; and this people will rise up, and go a whoring after the gods of the strangers of the land, whither they go to be among them, and will forsake me, and break my covenant which I have made with them. Then my anger shall be kindled against them in that day, and I will forsake them, and I will hide my face from them, and they shall be devoured, and many evils and troubles shall befall them; so that they will say in that day, Are not these evils come upon us, because our God is not among us? And I will surely hide my face in that day for all the evils which they shall have wrought, in that they are turned unto other gods.
And it came to pass, when Moses had made an end of writing the words of this law in a book, until they were finished, That Moses commanded the Levites, which bare the ark of the covenant of the Lord, saying, Take this book of the law, and put it in the side of the ark of the covenant of the Lord your God, that it may be there for a witness against thee. For I know thy rebellion, and thy stiff neck: behold, while I am yet alive with you this day, ye have been rebellious against the Lord; and how much more after my death?”
Deuteronomy 31:15-18, 24-27 KJV
he then as a second witness gives them the song of Moses after placing the book of the law of Moses next to the ark bearing the Ten Commandments for the purpose of being a witness against the people who avid had found to be rebellious and knew they would stray terribly after Moses death and go to mother gods the law became a witness against sinners because of the people
“Knowing this, that the law is not made for a righteous man, but for the lawless and disobedient, for the ungodly and for sinners, for unholy and profane, for murderers of fathers and murderers of mothers, for manslayers, For whoremongers, for them that defile themselves with mankind, for menstealers, for liars, for perjured persons, and if there be any other thing that is contrary to sound doctrine; According to the glorious gospel of the blessed God, which was committed to my trust.”
1 Timothy 1:9-11 KJV
and later on in the prophets God promised to speak forth his law from Jerusalem as Moses had already written in the law beforehand himself succeeding authority to the coming messiah who would speak Gods true word of requirement (Deuteronomy 18:15-19 , acts 3:22-26)
long after the law from Sinai there was a promise in prophecy that God would give a law
“
Hearken unto me, my people; and give ear unto me, O my nation: for a law shall proceed from me, and I will make my judgment to rest for a light of the people. My righteousness is near; my salvation is gone forth, and mine arms shall judge the people; the isles shall wait upon me, and on mine arm shall they trust.”
Isaiah 51:4-5 KJV
“And
many nations shall come, and say, Come, and let us go up to the mountain of the Lord, and to the house of the God of Jacob; and
he will teach us of his ways, and we will walk in his paths: for the law shall go forth of Zion, and the word of the Lord from Jerusalem.”
Micah 4:2 KJV
of course this happened through the disciples and great commission carrying the gospel to the world
“And said unto them, Thus it is written, and thus it behoved Christ to suffer, and to rise from the dead the third day:
And that
repentance and remission of sins should be preached in his name among all nations, beginning at Jerusalem. And ye are witnesses of these things.”
Luke 24:46-48 KJV
“And he said unto them, Go ye into
all the world, and preach the gospel to every creature. He that believeth and is baptized shall be saved; but he that believeth not shall be damned.”
Mark 16:15-16 KJV
“And Jesus came and spake unto them, saying,
All power is given unto me in heaven and in earth. Go ye therefore, and teach all nations, baptizing them in the name of the Father, and of the Son, and of the Holy Ghost:
Teaching them to observe all things whatsoever I have commanded you: and, lo, I am with you alway, even unto the end of the world. Amen.”
Matthew 28:18-20
He’s taught us his ways and sent forth the law from Jerusalem to all nations
“It is written in the prophets, And
they shall be all taught of God. Every man therefore that hath heard, and hath learned of the Father, cometh unto me.”
John 6:45 KJV