T he first time anyone on social media noted a crowd at a political rally chanting “CNN sucks!” was at a rally in Santa Monica, California, after the 7 June primary in that state.

It wasn’t one of Donald Trump’s rallies; he was back in New York City, pledging that he would soon be unveiling new derogatory information about Hillary Clinton shortly after a planned meeting between members of his campaign and a Kremlin-linked attorney (which he asserts he didn’t know about).

It was a rally for Senator Bernie Sanders, whose bid for the Democratic Party presidential nomination had been out of reach for some time but which the primaries that night officially made impossible. This was before WikiLeaks released documents stolen from the Democratic National Committee showing that CNN contributor Donna Brazile had leaked a question for a town hall event to the Clinton campaign.

The chant was “basically ... calling out the mainstream media for their coverage of the election,” one rally attendee said in a video shown on election coverage by the liberal Young Turks team. (That attendee was Brigida Santos, then a reporter for RT, the Russian government-funded television network.)

At the time, Trump’s once cosy relationship with CNN had only just begun to sour. By now, that relationship is toxic enough that Trump supporters chant “CNN sucks” with nearly the same alacrity that they chant, “Lock her up.” In part, certainly, it’s because the phrase has a rhythm that, say, “Washington Post sucks” does not. But in part it’s because Trump and his allies have increasingly used CNN as a foil in the mainstream media.

Before running for president, Trump’s relationship with CNN was like his relationship with nearly any other media outlet: If it had cameras running or if there was a reporter on the other end of the phone line, he was happy to talk. Trump was regularly interviewed by his friend Larry King when King had his show on CNN. He doesn’t appear to have offered many concerns about the network’s coverage while doing so.

Once he announced his candidacy, CNN was just another network. Trump regularly appeared on the network’s programmes, and the network covered his rallies, often in full. He sat for interviews with Anderson Cooper and Chris Cuomo and would call in to network shows.

He criticised the network’s coverage at various point, as when it was sceptical about his claim of being worth $10bn and when it covered a former employee who alleged that Trump had chastised her for breastfeeding.

Alarm goes off in CNN newsroom while on air as Time Warner Center evacuated

But CNN kept pumping out one form of news that Trump celebrated: Good poll numbers. As with other polls assessing the Republican primary field, Trump kept leading the field. He would regularly tout his latest good numbers at his rallies; with any bad news seemingly having no effect on his standing, he didn’t expend much energy mocking the network.

“CNN did this really very, very expensive, very well done poll — it’s only well done because I was leading by a lot,” Trump said in August. “If it wasn’t, I’d say it wasn’t. And they had leadership - I was way ahead of everybody.”

The first debate was on Fox News in August, and ratings went through the roof. The second was scheduled for mid-September on CNN, and Trump thought he saw a point of leverage. He sent the network a letter insisting that ad revenue from the debate be sent to charity groups focused on military veterans instead of into the network’s pockets. He had put a renewed focus on veterans following his comments disparaging Senator John McCain the month before.

“While I refuse to brag, and as you know very well, this tremendous increase in viewer interest and advertising is due 100% to ‘Donald J. Trump,’” he wrote in a letter to the network. CNN declined to take him up on his offer. The ratings for the second debate were also strong.

Trump supporters at a Trump rally in Wilkes-Barre, Pennsylvania in August 2018 (The Washington Post/Philip Bump ) (The Washington Post/Philip Bump)

In late November, he complained to a rally audience about a bad story from CNN (“I love hitting them!”), but by December he was praising the network again for its “great, great” poll that came out showing him in the lead in Iowa.

In January, his complaint about another “great” CNN poll took a different form, as he alleged that the network would not use its own poll in favour of one from another outlet. The theme over and over: CNN, like the rest of the mainstream media and the establishment, was out to get him, except when they had good news he could promote.

A string of four Trump tweets in January 2016 makes that odd relationship clear.

“New CNN/WMUR New Hampshire poll just released. Thank you! ”

“So sad that @CNN and many others refused to show the massive crowd at the arena yesterday in Oklahoma. Dishonest reporting!”

Donald Trump supporters demonstrating against anti-Trump protesters calling for the president's impeachment in Los Angeles (AFP/Getty Images)

“New Day on CNN treats me very badly. @AlisynCamerota is a disaster. Not going to watch anymore.”

“I will be on @CNNSitRoom with @wolfblitzer from 5-7pm est. on @CNN.”

Still appearing on the network. Still watching. Still embracing the polls. Still criticising the critics who got airtime.

After he secured the nomination, though, his rhetoric shifted. Gone were the polls showing him in the lead.

“CNN is so negative, getting even worse as I get closer,” he tweeted in late May. “Just had two anti-Trump losers with zero rebuttal from my team. Turning off!” By early June, he was referring to the network as the “Clinton News Network”.

“CNN is all negative when it comes to me,” he declared in late June. “I don’t watch it anymore.”

In early July 2016, Trump sent out a tweet featuring an image that showed Clinton’s face on a pile of money next to a six-pointed star. The anti-Semitic connotations of the image quickly became a cable-news conversation, as Trump tried to say it was intended to be a sheriff’s star.

At a speech in Cincinnati shortly after the controversy erupted, Trump’s rhetoric about CNN was stark.

“These people are sick, folks,” Trump said. “I’m telling you. They’re sick. And I’ll tell you: Someday I’m going to tell you the real story of CNN, but I’m not going to tell it yet. But they’re sick. I don’t watch it! Don’t watch it. You know what? Don’t watch it anymore.”

A few weeks later, the Republican Party held its convention. Trump’s poll numbers jumped shortly afterward.

“The CNN poll was so good, I may have to start liking them again,” he said, after CNN’s post-convention poll. Some in the audience booed at his comment, prompting Trump to chuckle.

Donald Trump supporters listening to the President speak at a rally in Huntington, West Virginia, on 3 August 2017 (Carlos Barria/Reuters)

At a rally on 29 July, Trump complained that CNN had accused him of wanting to “hit” speakers who were critical of him. Trump said that “obviously he was talking about his verbal”, hitting them in a speech or in a tweet.

“I’ll tell you, CNN is really - you know they call it the Clinton News Network. It’s really a dishonest group of people,” he said. “They are terrible.”

He then accused CNN of shutting off the camera that the network was using to cover the event. It hadn’t.

On 8 August Trump reacted to a CNN poll analysis that showed him down by 10 points.

“I see one from CNN where we’re down,” he said. “I think these polls - I don’t know. There’s something about these polls. There’s something phony.” After he became president (and as his approval numbers stayed well under 50 per cent), Trump tweeted that “any negative polls are fake news, just like the CNN, ABC, NBC polls in the election”.

Trump begs supporters to stay by him after Media attacks 'just stick with us... don't believe the cr*p the fake news tells you"

Trump’s denunciations of CNN continued sporadically for a few months. In October, the stolen DNC email revealing Brazile’s leak was published. At a rally that night, Trump railed against the network yet again, in part because of the leak and in part because the network’s commentators criticised his performance in the first presidential debate.

“If the late, great Abraham Lincoln debated, and he was representing our point of view, CNN would say Abe Lincoln went down to a massive defeat,” he said. “I mean, these are dishonest people we’re dealing with.”

The night before, on 10 October, the first recorded “CNN sucks” chant erupted at a rally in Wilkes-Barre, Pennsylvania.

Trump has often said that once he won the presidency, he expected the media’s rhetoric about him to soften. He said that specifically about CNN in late November 2016.

Trump tweeted “I thought that @CNN would get better after they failed so badly in their support of Hillary Clinton however, since election, they are worse!”

At a news conference in early January 2017, Trump set a new tone in his relationship with the network. Trump bashed the network repeatedly after CNN ran a story about a dossier of allegations concerning his campaign’s relationship with Russia.

The network’s Jim Acosta tried to ask Trump a question.

“Not you. Your organisation is terrible,” Trump said.

“Since you’re attacking us, can you give us a question? Mr President-elect, since you’re attacking our news organisation, can you give us a chance?” Acosta replied.

“I’m not going to give you a question. You are fake news,” Trump said.

(Acosta in particular has rankled Trump and White House staffers. In January of this year, Trump called him “crazy.” Press secretary Sarah Sanders has repeatedly clashed with him in the White House briefing room.)

The dossier and the Russia investigation have fuelled much of Trump’s frustration with the media as president. In February 2017, he dubbed CNN and other news organisations “the enemy of the American People!” He called CNN and other outlets “a great danger to our country” and said that CNN, like the New York Times, had “become a joke.”

In October of last year, the network pushed back, releasing a series of ads using a metaphor focused on apples to criticise Trump’s frequent lies and distortions.

CNN is broadly popular with Americans and is often seen as the nonpartisan competitor to MSNBC and Fox News. Trump’s base, though, was already primed to dislike CNN.

In a Suffolk University poll from June 2015, only 3 per cent of Republicans identified CNN as their most-trusted source of news or opinion. That jumped to 7 per cent shortly before the election, but in a poll this week, that figure was down to 1 per cent.

Trump tweeted “We should have a contest as to which of the Networks, plus CNN and not including Fox, is the most dishonest, corrupt and/or distorted in its political coverage of your favourite President (me). They are all bad. Winner to receive the FAKE NEWS TROPHY!”

The president’s most recent excoriation of the network came early Friday in a tweet lamenting CNN’s assertion that his rhetoric bore some of the blame for a recent spate of mail bombs sent to Democratic politicians and to CNN itself.

Support free-thinking journalism and attend Independent events

“Funny how lowly rated CNN, and others, can criticise me at will, even blaming me for the current spate of Bombs and ridiculously comparing this to September 11th and the Oklahoma City bombing,” he wrote, “yet when I criticise them they go wild and scream, ‘it’s just not Presidential!’”

A few hours later, a suspect in those attempted bombings was arrested in Florida. The suspect’s van was covered in stickers offering support for the president.

In one corner of one window was a familiar slogan: “Dishonest media / CNN sucks.”