Prepare ingredients: slice the onion into thin strands, prepare green onion and cilantro. Lightly crush the black cardamom with the back of a knife to release its aroma.
2
Pour the oil into a small pot. While the pot is still cold, add the crushed garlic and ginger slices. Turn to medium heat and let the aromatics release their fragrance.
3
Add the sliced onion, followed by green onion and cilantro. Reduce to medium-low heat and slowly fry the vegetables evenly. Press them down occasionally with a spatula to ensure they are fully submerged in the oil.
4
Continue frying on medium-low heat until the vegetables begin to dehydrate and turn golden-brown at the edges. Remove any darkened garlic pieces to prevent burning. Once the vegetables appear crispy and three-dimensional, remove from heat.
5
Strain the fried vegetables using a stainless steel sieve and set aside. The residual heat will continue to crisp them up.
6
Once the oil has cooled slightly, return to medium-low heat. Add the spices (star anise, black cardamom, cinnamon, clove, and Sichuan peppercorn) to the oil. Fry gently until fragrant, then remove with a slotted spoon.
7
Once the oil has cooled further, return some of the fried vegetables (keeping mainly the onion, ginger, and garlic) back into the oil to infuse. Let steep for at least one day to allow the vegetable flavors to fully permeate the oil.
8
Transfer the finished onion-infused spiced oil into a glass jar for storage. Use as a topping for noodles, dumplings, or other dishes as desired.