improved: load javasript from external file