If you're using a library that needs another lib then that lib will include the other. But if your app also needs it then it'll include it and it won't compile. In C and C++ they use #ifndef to prevent duplicate includes, that could also work here but a #include vs #insert might be a better choice so we can add all includes to a set and duplicate includes can be ignored. And for the situation where duplicate is fine or it's important that it's inserted where you want you can use #insert.
If you're using a library that needs another lib then that lib will include the other. But if your app also needs it then it'll include it and it won't compile. In C and C++ they use
#ifndefto prevent duplicate includes, that could also work here but a#includevs#insertmight be a better choice so we can add all includes to a set and duplicate includes can be ignored. And for the situation where duplicate is fine or it's important that it's inserted where you want you can use#insert.