Is css and html files necessary?

Given javascript can manipulate with the DOM tree and do all sort of things, I wonder why dont we just use one javascript instead to replace html and css files? Is that possible?

If that is possible, why are we still sticking to use html and css files still? Is it because historical reason?