Nearly two decades ago Lynn Hunt, the distinguished historian of the French Revolution, warned against the dangers of what she called "presentism." For Hunt, it was a regrettable development in historiography that "modernity became the standard of judgment against which most of the past, even the Western past, could be found wanting." It was instead the task of the historian, and of the student of history, to understand the past and "people who are hardly like us at all."

Hunt's concerns were justified in 2002 when her essay appeared in the magazine of the American Historical Association, of which she was then president. They are even more pressing now, when our commitment to judging the past by the standards of the present is matched only by our staggering ignorance of history itself. But it does not follow from an acknowledgement that the past was unlike the present that we should never denounce historical evils, much less fail to celebrate those who had the good sense to see them clearly at the time.

I cannot think of a better example of this than Samuel Johnson. The 18th-century man of letters who had the good fortune to become the subject of the first (and still perhaps the greatest) modern biography in our language was, even by the standards of his age, a reactionary crank. Dr. Johnson supported the restoration of the Stuarts to the English and Scottish thrones and bragged that in his (technically illegal) magazine summaries of parliamentary debates he "never let the WHIG DOGS get the best of it." He declared that "the first Whig was the Devil."

Perhaps it was this lonely vantage point that allowed Johnson to condemn the errors of his own age (and many that are still, alas, with us). His life (1709-1784) was more or less bookended by the beginning and end of the British transatlantic slave trade, of which he was an inveterate and uncompromising opponent. He dismissed Jamaica, the most profitable of the British colonies at the time, as "a place of great wealth and dreadful wickedness, a den of tyrants, and a dungeon of slaves." He once offered a toast at a dinner in Oxford to "the next insurrection of the negroes in the West Indies." His verdict on the American Founding ("How is it that we hear the loudest yelps for liberty among the drivers of negroes?") is in some ways the first and last word on the subject.

Nor was his belief in the wickedness of slavery a mere abstract commitment of the kind so familiar to scribblers then as now. Johnson's valet Francis Barber was a freed black Jamaican who eventually became his heir, an astonishing bequest that was widely reported in the English press at the time. With the help of his friend Tobias Smollett, Johnson secured Barber's release from naval service (for which he thought he should have been disqualified on grounds of health) and paid for him to receive an education. Johnson's relationship with Barber was one of genuine friendship and the latter was an invaluable source for James Boswell and other early biographers of the great man, including those like Sir John Hawkins who were disgusted by their subject's "ostentatious bounty [and] favour to negroes."

Johnson's loathing of racial injustice was not limited to chattel slavery. He heaped scorn on both colonial participants in the French and Indian War, which he called "only a quarrel of two robbers." Nor was this his only apparently forward-looking view. He hated the civil penalties under which British Catholics would live until 1829 and thought it absurd that in Rome of all places men were allowed to visit legally sanctioned brothels ("I would punish it much more than is done"). He also took a serious interest in medical ethics ("he surely buys knowledge dear, who learns the use of lacteals at the expense of his humanity") and was curiously obsessed with what we would now call animal cruelty:

Among the inferior professors of medical knowledge, is a race of wretches, whose lives are only varied by varieties of cruelty; whose favourite amusement is to nail dogs to tables and open them alive; to try how long life may be continued in various degrees of mutilation, or with the excision or laceration of the vital parts; to examine whether burning irons are felt more acutely by the bone or tendon; and whether the more lasting agonies are produced by poison forced into the mouth, or injected into the veins.

What made Johnson's views possible? In addition to his penchant for contrarianism, one might suggest his wide and generous reading, which attuned him to the experience of people far away and utterly unlike himself. (Among his favorite books was Richard Knolles's Generall Historie of the Turkes, the first serious English treatment of the history of the Ottoman Empire, which Johnson lamented was full of "enterprizes and revolutions, of which none desire to be informed.") More important than either of these, however, was his deep religious faith. Johnson could not stand to see "black men... repining under English cruelty" for the simple reason that he believed human beings are made lovingly in the image of God and possessed of an innate metaphysical dignity.

Whatever their origin, Johnson's views should be celebrated, not simply because they transcended the errors of his own but because they stand as an example to all people in ours and every age.

Want more essential commentary and analysis like this delivered straight to your inbox? Sign up for The Week's "Today's best articles" newsletter here.