Moved map js to separate file