Heat oil in a large skillet over medium heat. Add onion and garlic and cook until onion is softened, about 5 minutes.
Add scallions and ginger, and cook until fragrant. Stir in coconut milk and rice, and add salt to taste. Bring to a boil, and then reduce heat to low. Cover and cook, stirring occasionally, until the rice is tender; about 25 minutes. If more liquid is needed, add a small amount of water.
Transfer to a serving dish, sprinkle with the shredded coconut and cashews, and serve.