Jersey City Jewish deli killing to be investigated as domestic terrorism: Officials The motive seems to be "both anti-Semitism and anti-law enforcement" sentiment.

A pair of armed suspects, one wielding an AR-15 style rifle, who killed three people at a Jewish supermarket in Jersey City, New Jersey, moments after gunning down a police detective in a cemetery appear to have been motivated by "both anti-Semitism and anti-law enforcement" sentiments, officials said on Thursday.

The suspects, David Anderson, 47, and Francine Graham, 50, were killed in an hourslong shootout with police on Tuesday but left a trail of potential evidence investigators are combing through to determine why they allegedly killed Jersey City police Det. Joseph Seals and targeted the Jersey City Kosher Supermarket, officials said.

"Based on what we have collected so far, including based on recent witness interviews, we believe that the suspects held views that reflected hatred of the Jewish people as well as a hatred of law enforcement," New Jersey Attorney General Gurbir S. Grewal said at a news conference.

Grewal said killings are now being investigated as "potential acts of domestic terrorism fueled both by anti-Semitism and anti-law enforcement beliefs."

Craig Carpenito, U.S. attorney for the District of New Jersey, said the Federal Bureau of Investigation will take the lead in the probe.

"The motivation clearly appears to be a bias towards both the Jewish community and law enforcement," Carpenito said. "This is going to be investigated going forward ... as a domestic terrorism event."

The announcement came after law enforcement sources told ABC News that investigators had found religious writings by the suspects expressing hate.

In a stolen U-Haul van, the suspects parked in front of the kosher market just seconds before launching a rifle attack. Investigators found a pipe bomb and religious writings, including a handwritten note reading, "I do this because my creator makes me do this and I hate who he hates," multiple law enforcement sources told ABC News.

Grewal said five firearms were found at the scene, one an AR-15 style rifle that security video showed Anderson firing as he entered the supermarket around 12:30 p.m. on Tuesday.

"We also recovered a Mossberg 12-gauge shotgun, which we believe Francine Graham was carrying as she entered the supermarket," Grewal said.

Investigators also recovered from inside the store two other guns the suspects were armed with -- a 9mm Ruger semiautomatic handgun and a 9mm Glock 17, he said.

Inside the U-Haul van the suspects were driving, investigators also found a .22-caliber Ruger Mark IV handgun equipped with a homemade silencer and a homemade device to catch shell casings, Grewal said.

He said investigators recovered "several hundred shell casings" at the scene which investigators are processing to determine how many were fired by the suspects and how many were fired by the police.

Grewal said that based on two of the guns' serial numbers, the Mossberg shotgun and the .22-caliber Ruger, were legally purchased in 2018 by Graham at different gun shops in Ohio.

"At this point, our evidence indicates that the shooters were aiming their fire at law enforcement officers only and not at others on the street," Grewal said.

He said the investigation, so far, has found no accomplices involved. He also said investigators have learned that Anderson and Graham expressed interest in the Black Hebrew Israelites movement, a group that espouses hatred toward Jews and is known for anti-government and anti-police sentiments.

"We have not definitively established any formal links to that organization or to any other group. Based on the available evidence we believe that the two shooters were acting on their own," Grewal said.

Meanwhile, thousands of members of the Jewish Orthodox communities in Jersey City and Brooklyn, New York, gathered at cemeteries Wednesday night to mourn and bury two of the victims, 33-year-old Mindy Ferencz, the wife of the kosher supermarket owner and mother of five, and 24-year-old Moshe Deutsch, a Yeshiva student.

Deutsch's father, Abe Deutsch, is a member of the United Jewish Organization's board of directors, said Rabbi David Niederman, president of the organization.

“A few hundred bullets went into the body of a 24-year-old child ... how can we as a community, as people, bear that?” Niederman said of Moshe Deutsch, during a news conference Wednesday at City Hall in New York City.

The third victim killed at the supermarket was identified by authorities as Douglas Miguel Rodriguez, 49, who worked at the store. Funeral arrangements for Rodriguez are pending.

A funeral for Det. Seals, 39, a married father of five, is scheduled to be held next Tuesday.

New Jersey Gov. Phil Murphy said the Jersey City incident is a wakeup call.

"The murder of innocent civilians because of their religious beliefs, and the murder of a police officer for the simple reason that he was a police officer, must be the wakeup call to those who fail to see or acknowledge the rising tide of hate here in New Jersey, and around the nation,” Murphy said in a statement. “This is our signal to come together as the broad New Jersey family we are and recommit to the elimination of hate in all its forms."

The terrifying episode began to unfold about 12:38 p.m. on Tuesday when the Jersey City Police Department received a 911 call from an individual who discovered Seals' body in the Bayview Cemetery, about a mile from the kosher market, Grewal said on Wednesday.

He said investigators believe Seals was shot to death when he confronted the suspects in Bayview cemetery. He said Anderson and Graham were prime suspects in the murder this past weekend of an Uber driver officials identified as Michael Rumberger.

Rumberger's body was found in the trunk of a Lincoln Town car around 10 p.m. Saturday, sources told ABC News.

Seals apparently had gone to the cemetery alone to meet the suspects and one of them may have been an informant he had worked with, possibly explaining why he felt comfortable meeting in the cemetery without backup or radioing in about the rendezvous, the sources said.

Seals, a plainclothes undercover detective, had been investigating the homicide, according to law enforcement sources.

After allegedly killing Seals in the cemetery, the suspects got into the stolen U-Haul van and drove to the kosher market, arriving about 12:43 p.m., Grewal said.

Security video, obtained by ABC News, shows the suspects parking directly across the street from the supermarket on Martin Luther King Drive, getting out of the vehicle holding rifles and calmly walking into the supermarket as passersby on the street scrambled for cover.

Grewal said four people, including the three slain victims, were inside the store when the suspects stormed through the front door. A lone survivor, who was shot and wounded, managed to escape, Grewal said.

Two foot-patrol officers were about a block from the deli and responded as soon as they heard the gunfire, Grewal said. They were both shot and wounded in a gunfight with the suspects that involved other Jersey City police officers, he said.

The gunbattle lasted until about 3:47 p.m. when a police armored vehicle broke through the entryway of the supermarket and police found the bodies of the suspects and the three victims inside.

In addition to the two other officers wounded in the shootout, a third was hurt by shrapnel, officials said. The officers were all treated at a hospital and released.

ABC News' Rachel Katz contributed to this report.