Update script.js

Added gist and comments