Every page have a custom code property where you can put some code in the head of a page (between <script> my code; </script>) but it will only appear after you published your project.
From what I’ve seen with custom library, I think you will need to create a new component… can’t say for sure tho, @weweb-team might have better answer.