Maryland Del. Aruna Miller (D-Montgomery) is running for the Democratic nomination for the open 6th Congressional District seat. (Ricky Carioti/The Washington Post)

SOME DOWN-BALLOT Republicans, having seen Donald Trump exploit fear and hatred of immigrants during the presidential campaign, have been trying it themselves — at their peril. That strategy was central to Ed Gillespie’s gubernatorial campaign last fall in Virginia, where he conflated illegal immigration with gang violence, flooding the airwaves with ads featuring a chilling image of a hooded Hispanic gang member. He lost in a near-landslide.

The lesson seems to have been lost on Republicans in neighboring Maryland, where the state party apparatus, taking a page from Mr. Gillespie’s tattered playbook, has launched an odious attack on a Democrat running for the open 6th Congressional District seat for “treating criminals like celebrities” and inviting threats from MS-13 gangs who have “invaded neighborhoods.”

The object of the Republicans’ ire is state Del. Aruna Miller, a highly respected lawmaker from Montgomery County who is one of the putative front-runners in a field of more than a half-dozen Democrats running for the party nomination in a race to succeed Rep. John Delaney. (Mr. Delaney is leaving Congress to run for president.) Her transgression, according to a mass mailing from the state Republican Party, was to have been one of 58 legislators in Annapolis to co-sponsor legislation that would bar state and local authorities from asking individuals about their immigration status. The measure died in the House of Delegates.

That’s a pretty flimsy basis on which to link Ms. Miller with violent gangs such as MS-13. But it’s no flimsier than the pretext in another mailer — accusing her of “making your neighborhood go downhill” because she backed a bill to allow community-based organizations to establish centers to treat drug addiction and infectious diseases. That, according to another Republican mailer, would “bring drug dens to our neighborhoods” and “jeopardize your family’s safety.”

The Republican playbook is all about fear. By wallowing in wedge issues and demonizing The Other, the party hopes to frighten voters out of their wits — and into voting for GOP candidates who, like Mr. Trump, would capitalize on division by flirting with the electorate’s most noxious elements.

In fact, there are sound arguments for the legislation for which Ms. Miller is being pilloried. State and local law enforcement officials are not federal immigration agents, nor are they trained in that capacity, and they have a strong interest in forging bonds with immigrant communities — bonds that might be strained by questions about immigration status. As for allowing drug treatment in community settings, that might be one way to encourage addicts to get the help they need amid an escalating opioid crisis.

Ms. Miller is clearly seen by Republicans as a formidable opponent; they wouldn’t have spent money on the mailers if she weren’t. But by twisting her stances and doubling down on the politics of disunion and dread, Maryland Republicans do more to demean themselves than to define Ms. Miller.