Corned Beef on Rye with Caramelized Onions and Sauerkraut

Yield: 1 Servings
3cThinly sliced onion
2tbVegetable oil
3/4cDrained sauerkraut
1/2Granny Smith apple; grated coarse
Unsalted butter; softened, for buttering bread
8lg1/2-inch-thick slices rye bread
1lgGarlic clove; halved
1lgDill pickle; sliced paper-thin
3/4lbThinly sliced chilled cooked corned beef; (about half a cooked 3 1/2-pound corned beef; recipe follows)
1cCoarsely grated Swiss cheese
Mustard as an accompaniment