established server connectionand created a separate js folder