It should be noted, however that some states have statutes that address the prefiling period. Until permitted by order of the court, neither parent shall remove any child from the jurisdiction of the court or from any parent with whom the child has primarily resided for the sixty days immediately preceding the filing of a petition for dissolution of marriage or legal separation. This clearly restricts the range of options otherwise available before filing. In the absence of such a statute, you can make a decision as to whether you will file with or without children in your care. In some jurisdictions this can be a key decision.
Many courts refuse to try a custody dispute twice.
As a practical matter, what that means is that the court will not hear a full-blown trial over custody at the temporary hearing and then suffer through what would presumably be the same or similar evidence at the final hearing. Depending on the waiting period for a trial, the interim custodial arrangement could substantially advance or reduce your chances of victory at the final hearing. Often a case remains pending in excess of 1 year before it actually goes to trial. This affords an opportunity to the interim custodial parent to create a record of exemplary parenting, and indeed for some, it is a necessary period to rehabilitate their image as a parent. Additionally, the interim parent benefits by creating a somewhat settled status quo going into trial.