Heat olive oil over medium heat in a large soup pot. Add the sliced onions and cook until they start to soften, around 20 minutes, stirring regularly to avoid burning.
Once the onions start to caramelize, add the butter and continue to caramelize and brown them, stirring often, for around 15 minutes more.
Add the salt and sugar and continue cooking for around 10 minutes more, until onions are well browned, but not burnt. Add garlic and cook until fragrant, around 1 minute.
Add the wine (or vegetable broth if you don't want to use wine) and scrape the bits of onion from the pan, combining well.
Add the vegetable broth, Worcestershire sauce, thyme, black pepper and bay leaves. Simmer for around 20 minutes, covered.
While the soup is simmering, preheat the oven to 350°F. Brush the slices of bread with olive oil and place in a baking sheet. Toast in the oven for around 10 minutes, flipping the bread at the 5 minute mark.
Once the soup is done, serve in oven proof bowls, top with a toasted bread slice, and sprinkle the shredded cheese on top. Place the bowls in a baking sheet, and broil until cheese is melted and bubbling.
Serve immediately and top with a dash of grated Parmesan cheese, if desired.