When one works in more than one state, both the home state and the work state will tax the income. The home state will then credit the taxpayer for the taxes paid to the work state on that income to avoid double tax on the same income.
Some border states have a reciprocity agreement where income earned in the border state is considered income earned in the home state so that only the home state will tax that income
For residents of AZ, CA, OR, IN and VA, when one lives in one of the listed states and works in the other, the credit goes in “reverse” . For example when a VA resident works in CA, the credit to relieve double taxation is allowed by CA, not the home state VA. IN and CA have dropped their reverse credit arrangement as of the 2017 tax year. For tax years 2017 and later, IN will allow a credit for taxes paid to CA against IN state tax obligations on the same income. (Note: IN and VA do not share this arrangement).