This book of the law shall not depart out of your mouth, but you shall meditate thereon day and night, that you may observe to do according to all that is written therein: for then you shall make your way prosperous, and then you shall have good success.
"According to all the law  ..." Yes, indeed, according to this testimony, even in the days of Joshua, there was a "Law of Moses," containing all that the Israelites were expected to do!  Efforts to make the Pentateuch itself a late book by dating from the times of the judges, or the monarchy, or the post-exilic priesthood are among the most stupid and impossible tasks the so-called "higher critics" ever assigned themselves!  This is as good a place as any to take a little closer look at what the Word of God says concerning this: