map js move from header to separate file