Cook the onion in the oil on a griddle over medium heat for 12 to 15 minutes until soft and deeply golden, then move it to a bowl.
Mix the mayonnaise, ketchup and relish and spread the sauce on the cut buns.
Divide the beef into 4 loose balls, place them on a hot griddle, smash to 1/3-inch thickness and season with salt.
Cook for 2 minutes, spread mustard on the raw tops, then flip and cook until the beef reaches 160°F.
Add cheese and onions, cover for 30 seconds until the cheese softens, and close each patty inside a prepared bun.