A Democratic congressman says journalists need a federal law to protect them from violence.

Speaking on CNN's "Reliable Sources" Sunday, Representative Eric Swalwell said his bill, which was introduced last week, aims to protect "journalists in every corner of our country if they are attacked physically while doing their job."

The bill, which is called the Journalist Protection Act, would make it a federal crime to cause "bodily harm" to reporters.

Swalwell has accused President Trump of creating a "toxic atmosphere" in which people feel emboldened to attack members of the press.

"I really wish I didn't have to introduce this, but we have seen rhetoric from the president declaring the media as the 'enemy of the state,'" Swalwell said.

Some argue the bill isn't necessary. Amy Swearer, a visiting legal fellow at the conservative Heritage Foundation, wrote in a column published last week that Swalwell's measure "serves little practical purpose."

Related: John McCain tells Trump to lay off the 'fake news' claims

"The general police power—that is, the broad authorization to enforce criminal law—is reserved to the individual states by the 10th Amendment," Swearer writes. "The federal government's ability to enact and enforce criminal statutes is limited."

She also points out that last year, 70 journalists were killed and 262 were imprisoned around the world, but not "one of those deaths or imprisonments occurred in the United States."

But in a press release, Swalwell pointed to several incidents, including a March 2017 incident involving an OC Weekly reporter, two photographers and demonstrators at a Trump rally in California

"Reliable Sources" guest host Frank Sesno also pointed out that last April, Greg Gianforte -- on the eve of the election that made him a U.S. congressman -- body slammed a reporter.

In November, a staff member for Senate candidate Roy Moore shoved a Fox News camera crew at a rally in Alabama. Moore lost his special election bid for the Alabama seat.

Related: President Trump focuses anti-media ire on NBC after Tillerson 'moron' report

"I'm afraid that many journalists will continue to come under attack, and I want to make sure that if its politically unpopular in a particular part of the country to prosecute someone who abuses a journalist that there's a federal backstop," Swalwell said Sunday.

He added that the legislation would not penalize someone for critiquing reporters or their news coverage.

"This would only allow prosecution if a journalist was physically attacked," he said. "It doesn't limit anyone from criticizing the press. Donald Trump can go along his way and continue to declare the press 'the enemy of the state.' That's not good for democracy, but that wouldn't be a crime here."

The bill has 12 co-sponsors, all of whom are Democrats. Swalwell said he's reached out to conservative members of Congress, but so far none have agreed to sign on.