Classic Barbecue Pork Ribs with Smoky Bacon Barbecue Sauce

Ingredients:
5 cloves garlic, minced
1 tablespoon plus 1 teaspoon kosher salt, preferably Diamond Crystal
1 tablespoon packed dark brown sugar
1 tablespoon smoked paprika, preferably Pimentón de la Vera*
2 teaspoons ancho or New Mexican chile powder
2 teaspoons freshly ground black pepper
2 teaspoons chopped fresh sage leaves
1 teaspoon chopped fresh thyme leaves
"1 teaspoon dry mustard, preferably Colmans", 1/2 teaspoon ground cumin
1/2 teaspoon ground coriander
1/2 teaspoon ground ginger
1/2 teaspoon cayenne pepper (optional)
2 slabs St. Louis–style pork spareribs (about 7 pounds total) or 2 slabs pork spareribs (about 8 pounds total)
6 ounces bacon, diced
2 medium onions, finely chopped
5 cloves garlic, minced
2 teaspoons chopped fresh sage leaves
1 teaspoon chopped fresh thyme leaves
2 tablespoons smoked paprika, preferably Pimentón de la Vera*
1 tablespoon ancho or New Mexican chile powder
1 teaspoon ground cumin
1 teaspoon freshly ground black pepper
1/2 teaspoon ground ginger
1 cup brewed coffee
2 tablespoons packed dark brown sugar
2 tablespoons yellow mustard
1 tablespoon Worcestershire sauce
2 tablespoons cider vinegar, plus more to taste
1 cup ketchup
Few dashes hot sauce, such as Tabasco, plus more to taste
3 fresh or 2 dried bay leaves
Kosher salt
"*Smoked paprika is available at most supermarkets. Pimentón de la Vera is a sweet red chile grown in the La Vera valley of western Spain
and slowly smoke-dried before being ground into a powder. Its available at specialty food stores and online at LaTienda.com. Hungarian smoked paprika is a good substitute."
Equipment: Large
rimmed baking sheet; flat metal cooling rack

Instructions:
In a small bowl, combine the garlic, salt, brown sugar, smoked paprika, chile powder, black pepper, sage, thyme, dry mustard, cumin, coriander, ginger, and cayenne pepper if using. Generously coat the ribs with the rub then wrap each slab in a double layer of plastic wrap and let them sit at room temperature for up to 2 hours. DO AHEAD: To develop maximum flavor, place the ribs, coated in the rub, in the refrigerator and chill at least 12 hours and up to 24 hours.
Preheat the oven to 325°F.
Line a large rimmed baking sheet with foil. If you have a flat metal cooling rack, arrange it in the baking sheet and place the ribs, bone side down, on the rack. If you don't have a rack, place the ribs, bone side down, directly on the foil-lined baking sheet. Bake the ribs until the meat is tender and starting to pull away from the bones, 1 1/2 to 2 hours. At this point, the ribs are ready to be served, but we recommend taking the time to finish them on the grill (or in the broiler), while glazing with homemade barbecue sauce. DO AHEAD: Ribs can be baked ahead of time and kept, wrapped in foil, at room temperature for 4 to 6 hours, before finishing them on the grill.
In a heavy, medium saucepan over moderately low heat, cook the bacon until the fat renders and the bacon starts to brown, about 10 minutes—do not let the bacon get crispy. Add the onions and continue cooking, covered and stirring occasionally, until the onions are soft and translucent, about 10 minutes. Add the garlic, sage, and thyme and cook, stirring occasionally, for 1 minute. Add the smoked paprika, chile powder, cumin, black pepper, and ginger and cook, stirring, for 1 minute. Add the coffee, brown sugar, yellow mustard, Worcestershire sauce, and vinegar and stir well to combine. Raise the heat to moderate and bring the sauce to a boil, scraping the saucepan with a wooden spoon to remove any browned bits from the bottom. Add the ketchup, hot sauce, and bay leaves, then lower the heat to moderately low and simmer the sauce until it's thick enough to coat the back of a spoon but isn't as thick as ketchup, about 30 minutes. Taste the sauce and add more vinegar or hot sauce to taste and season with salt and pepper. Remove and discard the bay leaves. DO AHEAD: BBQ sauce can be made ahead and stored, in an airtight container in the refrigerator, up to 2 weeks. Warm the sauce gently on the stove before using.
While the barbecue sauce is simmering, prepare your grill for direct-heat cooking over medium-high heat: If using a charcoal grill, open the vents on the bottom of the grill and light a large chimney starter full of charcoal (preferably hardwood). When the coals are covered with white-gray ash (about 20 to 30 minutes later), spread them out on the grill's bottom rack, leaving a space to one side that is equal to the size of the food to be grilled so that it can be moved there in the case of flare-ups. Test the heat of the charcoal by holding your hand 5 inches above the coals for about 3 seconds for medium-high heat. If the charcoal is too hot, continue to let it burn until it reaches medium-high.
If using a gas grill, preheat all burners on high, covered, for 10 minutes, then adjust the heat to medium-high.
Depending on the size of your grill, place 1 or 2 slabs, bone side down, over the heat and brush the fat-covered side generously with barbecue sauce. Grill the ribs, covered, for 2 minutes. Flip the slab over, brush the bone side with sauce, and grill, covered, until the sauce on the fat-covered side is caramelized and lightly charred, 1 to 2 minutes. Flip the slab over and continue grilling, covered, until the sauce on the bone side is caramelized and lightly charred, 1 minute. Transfer the ribs to a cutting board and let them rest for 10 minutes. If necessary, repeat the grilling and glazing process with the second slab of ribs. Cut between the ribs and serve immediately with plenty of barbecue sauce on the side.