During a discussion about LGBT rights, US President Donald Trump joked his Vice-President wanted to "hang all gay people".

Trump, talking to a legal scholar during a White House discussion on gay rights, mocked Mike Pence's religious beliefs and social conservatism, The New Yorker magazine reported.

Vice-President Mike Pence on a visit to California last week to raise money for endangered Republican congressional candidates. Credit:AP

The comments were printed in a profile of the 58-year-old second-in-command, under the headline: "The danger of President Pence".

According to the magazine, two sources said Trump was known to needle Pence about his views on abortion and homosexuality.