The best way to do it would probably be to use JSONP to contact your server, where you have a list of domains that are allowed to use it, and check the referer [sic] header. That said, this isn't a bulletproof solution, as the referer [sic] header isn't required to be sent. Also, as this is a Javascript library, they could always modify the source, but you could make it harder by using the YUI Compressor along with Dean Edward's packer to make the code as hard as possible to understand, and therefore hard to get around.
That said, not to be rude, but why would people want to use your script for a fee, when they could use jQuery, which is free and has a large community of free plugins, and many people willing to help for free, for your library that costs a fee, and probably costs for support as well?