How to use javascript code in Wix button?

Please see Wix Velo Reference https://www.wix.com/velo/reference/$w/button

Using other thing outside of this ref. , I can sure 99% result in error