The latest world premiere at Berkeley Rep by playwright Sarah Ruhl is a complex and darkly funny look at the Salem Witch Trials through the lens of contemporary American malaise, the #MeToo movement, and Donald Trump.

It's called Becky Nurse of Salem, and it centers on Becky Nurse, a woman in her early sixties who's a descendant of Rebecca Nurse — one of the "upstanding" citizens of Salem who was caught up in the hysteria of witch accusations in 1692, and whose death sentence may have ultimately helped sway public opinion against the trials. The latter-day Nurse is, appropriately, a tour guide at the Salem Witch Museum in present-day Massachusetts, and an outspoken expert on the Witch Trials and the characters involved. Speaking to a high school group in the opening scene, for instance, she points out that Abigail Williams, the young girl who torments John Proctor in Arthur Miller's play The Crucible, wasn't 17 in real life as Miller wrote but was in fact 11 — and the real story was likely one of molestation and not one of seduction by a young woman. She also is certain that Gallow's Hill, where hundreds of people died in Salem, is where a Dunkin' Donuts now stands.

Ruhl has had a habit in her work of wanting to revise historical and cultural narratives through a feminist — or a more accurately female-centric — lens. And Becky Nurse of Salem is admittedly her answer to Miller's play, which while brilliant is still an enraging text that casts witchery in the context of a young woman's desire for an older man. In his own biography, Miller admitted that he found in Proctor a character that could somehow absolve him of his own moral ambiguities — namely his desire to have sex with Marilyn Monroe, to whom he was married for five years following a marriage he was still in while he wrote The Crucible.

As Ruhl writes in a program note, "The fact that The Crucible is done at almost every high school, and is in fact the way American girls and boys understand the history of Salem, added to my frustration... I thought: no one to this day knows why the girls engaged in mass hysteria, but it probably was not the lust of one duplicitous 11-year-old for one middle-aged barkeep."

Enter Becky (played by the marvelous Pamela Reed), who has no patience for fools, doesn't mince words, and who is promptly fired from the tour guide job she's had for 20 years after failing to properly edit herself in talking to a group of teenagers. Becky is flawed, with an addiction to opioid pain pills, but she's been doing her best to care for her teen granddaughter Gail (Naian Gonzalez Norvind) who was just hospitalized for depression.

Becky ends up engaging the services of a modern-day witch (Ruibo Qian) in order to help her get a new job, and to pay the witch she ends up borrowing some money from her friend Bob, a bartender, on whom she's had a crush since high school. Without spoiling too much, let's just say that Becky breaks a couple of laws and ends up on trial in Salem herself, and Ruhl's dark comedy takes on some pathos as Becky struggles to explain herself to the world.

The play succeeds in its sharp dialogue and many hearty laughs — some at the expense of strip-mall-filled, working-class Massachusetts, with a running joke about a historical site at a Walgreen's. And Ruhl has mashed up Trump era politics into the script as well, which may not age well but, for the moment, offers some satisfying re-contextualizing of the term "witch-hunt," not to mention the 2016 chants of "lock her up!"

Ruhl wants to make sure, above all, that audiences walk away remembering that women were at the heart of the mass hysteria of 1692 — namely a few independent, non-conforming, in a couple of cases land-owning women. And it continues to often be women who get singled out for certain kinds of villainy, even if they no longer get sentenced to death over vague accusations of necromancy or spell-casting. And she's less interested in explaining the history — by one theory, toxified rye bread might have induced hallucinations or the spasms observed in the girls of Salem; by another, a rash of dead infants, which were all too common, may have put the women in the community in a particular state of collective grief and mental instability.

"Hysteria" was the topic of Ruhl's most successful play to date, which also premiered at Berkeley Rep: 2009's In the Next Room, or The Vibrator Play. And women's sexuality figures into Becky Nurse of Salem in some similar if more subtle ways, and with similar humor. But at the root of both plays Ruhl is questioning how society miscasts and misunderstands female desire, and the emotional lives of women. In this play, we see her also looking at a modern-day American town where no one is particularly thriving, and where there's a lot of history but no great outlook for the future. It's a museum to itself where a resident like Becky isn't above paying a witch to solve some of her problems.

The direction by Anne Kauffman plays up much of the humor and has some great fun with the "museum" setting of Salem — complete with goofy life-size wax figures who don't just stand still.

Becky Nurse of Salem may still be in need of some polish and chiseling, but it's a fine and funny work from a playwright still at the top of her game.

'Becky Nurse of Salem' plays through January 26 at Berkeley Rep. Find tickets here.