My wife was recently granted an EEA FP but it is valid from the 21st of June she is only able to get a flight to the UK for the 23rd. If the UK leave the EU will it be a problem for her to get a resident card afterwards also is it a problem that she has there on the 23rd.
The UK will most likely remain a member of the EU until at least 2018. All of the current EU/EEA laws still apply until that date. No one knows what will happen afterwards.
Although the referendum is passed, nothing much will change overnight. As of 24/06/2016 the current plan is to invoke Article 50 around October 2016.
Invoking this article will start the withdrawal process, and the two parties (UK and the rest of the EU) will have two years to get an arrangement on the future. Until that arrangement is made (or the two year period is passed without any resolution), the UK will still remain a member of the EU, and all EU treaties will still apply.
Although it is possible that there will be an arrangement within a few months of invoking Article 50, as there are a lot of treaties to renegotiate, it is more likely it will take the full two years for everything to settle, until which date the UK is still part of the EU, and all of the EU treaties still apply. It might also be possible that because of the amount of treaties involved the two parties will extend the two year deadline.
What will happen after the arrangement has made: no one knows. Whether you or your wife will need new visas, or can still remain in the country will depend on the new rules that will be made during this period. The best thing you can do is to constantly check upon the news on the new laws and regulations that will be in place once the UK leaves the EU.
Although the UK referendum is on the 23rd of June, nothing will change immediately regardless of the outcome to vote.
If the result is to remain, nothing will radically change any time soon.
If the result is to leave:
In the short term, nothing will radically change. It will take years to negotiate the new status. The Leave campaign has not provided a proposal with any consensus, and any proposal would have to pass through Parliament and be negotiated with the EU and its member states.
In the long term, nobody currently (9 June 2016) knows what will happen so we cannot answer the question.