Preheat the oven to 375°F (190°C). Lightly grease a large baking dish with olive oil.
Bring the vegetable stock to a boil in a saucepan and then add the cashews. Cover the pot and remove from the heat, allowing the cashews to steam for 15 minutes.
Place the vegetable stock and cashews, along with the garlic, mustard, olive oil, nutritional yeast, vinegar, and salt in a blender.
Blend until completely smooth to form the béchamel. Then stir or pulse in the rosemary.
Slice the potatoes evenly into thin rounds, approximately 2 mm thick. If you have a mandolin, it’s a good way to ensure all of the slices are evenly thick.
Spread one-third of the potato slices in the prepared baking dish. Top with one-third of the onion slices, then pour over one-third of the béchamel. Repeat the layering process two more times, finishing with béchamel on top.
Cover the dish tightly with foil and bake for 45 minutes. Remove the foil and continue baking until the potatoes are tender and the top is golden, 30-35 minutes.
Garnish with fried onions or shallots, vegan parmesan, and chives.