No, you couldn't. Back then, the web was split between two major browsers: IE and Netscape. However, the feature set of what was supported in JS was not only completely different among the two, but also completely different among different minor versions of the two. Things that worked on Netscape 6.x would be broken on 6.(x+1), and work again in 6.(x+2), although with a different calling convention. It was mind-numbingly frustrating, and I don't think it would have been humanly possible to write JS that supported all minor iterations of each browser and maintained any sort of complex functionality.
By contrast, in 2006, I wrote a JS library that worked on IE6, Firefox 1.0+, and some early version of Safari. It has worked ever since, among dozens of versions of those browsers. That's the difference.
(Edit: I'm struggling to remember what version Netscape was around 10 years ago; the version number above might be wrong.)