Linting and formatting of the js codes

Linter forces to not have space before newline