If you are a U.S. citizen or resident alien, you are taxable in the U.S. on your worldwide income. If your Canadian salary is taxable in Canada, you can claim a foreign tax credit on your U.S. tax return (via Form 1116) to avoid double taxation.
A direct credit against your U.S. federal tax on can be claimed for the federal and provincial income tax paid to Canada on your Canadian- source salary, plus your Employment Insurance (EI) premiums paid. The credit is based on the lesser of the Canadian tax and the U.S.
tax on the income, such that you generally are subject to tax at the higher of the Canadian and U.S. average tax rate on the income.
Note that the credit is based on the actual tax per your Canadian tax return, as opposed to what was withheld at source from your salary.
Since Canadian tax rates are generally higher than U.S. tax rates, employees usually find that the foreign tax credit is sufficient to bring the U.S. tax on employment income down to zero. However, if you have other sources of income (e.g. investment income), you may still end up paying some U.S. federal tax, because Canadian tax on salary cannot be used to offset U.S. tax on passive income.