Cook the spaghetti according to package instructions in a large pot of salted boiling water until al dente. Drain and set aside.
In a large skillet, heat the olive oil over medium heat. Add the chopped onion and sauté for about 3-4 minutes until translucent.
Add the minced garlic and ground beef to the skillet. Cook until the beef is browned and cooked through, breaking it apart with a spoon, about 5-7 minutes. Drain excess fat if necessary.
Stir in the diced tomatoes (with juice), Italian seasoning, salt, and black pepper. Simmer for 5 minutes to allow the flavors to meld.
Reduce the heat to low and stir in the heavy cream and Parmesan cheese. Cook for an additional 2-3 minutes until the sauce is heated through and slightly thickened.
Add the cooked spaghetti to the skillet and toss to coat the pasta evenly with the creamy sauce. Cook for another minute until everything is heated through.
Serve immediately, garnished with fresh basil leaves if desired.