Best way to import 3rd party packages for only one page with Sage 9

I have a specific page template that requires several 3rd party packages. I’m currently adding them with yarn, and then importing them from /scripts/main.js which works great.

However, I’m wondering if this means that all pages will load these additional 3rd party packages, even though they don’t need them. And if so, is that a bad practice and is there another way I should be handling small sections of the sites with a lot of dependencies? Enqueue them seperately and only for that page? O