23:6-8
Joshua had been urged to be strong and courageous, and he now passes this encouragement, indeed this command, to the people. They must also be careful to obey the Law of Moses, not turning to the right nor to the left. They were not to associate with the nations. This was not because of racist reasons, but so that they would not adopt the ways of the nations, in particular worshipping false gods. Instead they were to hold fast to the Lord.
23:9-11
Joshua reminds the people of what God has already done for them. The nations they defeated were “great and powerful”, naturally speaking they presented a threat to Israel, but because the Lord was with them these nations could not withstand Israel. In our own lives we should not fear when we face problems or situations which are more powerful than us, for our lives are not based just on what we can do, but on what God can do through and with us. But these victories come with a warning. The danger is that while we may start off trusting in the Lord, after success we may start to trust in ourselves. Instead we need to “be very careful to love the Lord”.