I'll answer the question in the title which doesn't really match the question content, just for the benefit of those googling and ending up here:
This tool is very useful for showing a dependency tree for any project: https://github.com/marss19/reference-conflicts-analyzer
VS2022 extension link: https://marketplace.visualstudio.com/items?itemName=MykolaTarasyuk.ReferenceConflictsAnalyserVS2022