TL;DR
I answer that in good measure in question What is the programming paradigm used by Javascript?. So I start by saying Javascript is multi-paradigm, among them object orientation.
Introducing
I talk about What is a paradigm?. By this definition JS is essentially imperative and has some features that facilitate object orientation. It is important to understand What is the difference between a class and an object?.
I talk about the Meaning of terminology: "Object oriented". There is no definitive answer there, there is much controversy about what OOP really is. I will talk here about what is most accepted in programming (not in design) and that can help define whether the language is object-oriented or not. There defines what is an object that is important to begin to understand if there is guidance.
There are other definitions I don’t like so much: What is "Object-oriented" and what other methods?. There is also a question whether There is a class in Javascript? and is an important reading. Further reading: Functional Programming and Object-Oriented Programming. What are and what are their main differences?.
Remembering that you can do object orientation up to Assembly. Or in C: Object oriented programming in C is possible?.
It’s not so clear whether it is or not
By all definitions I found JS is OO (as secondary paradigm). To a lesser degree than other languages. It is more specifically oriented to prototypes, which are still objects. A prototyping is a branch of object orientation. Language is not class-oriented.
If you still don’t believe, read the documentation that is considered official. Note that they do not say that language is object-oriented. In a certain way no language is of a paradigm. You apply paradigms to your code. But of course languages encourage a certain paradigm.
JS encourages object orientation? It depends on the OOP definition you use and depends on the definition of what it is to encourage.
You call members of a structure, including functions/methods, referencing themselves by the object primarily. Some say this is enough to be object-oriented. Others will say you need to be able to do inheritance, polymorphism and encapsulation.
- An object can be created based on an existing one - which will be a prototype of this one (see example in other answers);
- an object can assume different behaviors consistently with its "family";
- an object can hide the details of how it works.
It can be argued that syntax is not the most convenient to do this. But it is very easy to understand how it works. There are specific mechanisms that "encourage" to do these things. If they are enough I do not know, I think that there we fall into subjectivity. Objectively the mechanisms exist.
Some say that it is necessary to abstraction and/or overload operators. But there are few sources that cite these characteristics as mandatory and are not the most reliable. It is possible to do abstraction in JS, but there is no specific mechanism. Anyway it is one more thing than design. Operator overload doesn’t really have anything, but it’s a controversial feature if it’s part of OO. Java doesn’t do this and no one questions whether the language is object-oriented.
As a matter of fact, I know a lot of people who don’t find class syntax that convenient. Of course, they are so used to the prototypes that it makes it difficult to adapt.
On the other hand there are those who say that OOP is about the code reuse. JS is one of the simplest languages to get this. If you say OO is to put state together with behavior, it is quite easy, the fact that it is optional to do so does not change anything.
There is no purity in JS. But what language is pure? Nor is it a good feature.
The fact that it is prototypeoriented does not eliminate the fact that it is object oriented as well as it does not eliminate the fact that it is mainly imperative.
SE6
Ecmascript6 brought the classes to the language. Note that there were no important semantic changes. Basically there is a new syntax to do what was already possible, now with classes. Syntax is important, of course. We always say that C can be programmed object-oriented, even without the language being. JS had no facility to write classes, although objects could be created without them.
Now JS is oriented to prototypes and classes. Has anything changed in relation to object orientation? I don’t think so. If nothing has changed, it seems that the language was already object-oriented before classes existed.
Who can’t use ES6, can use Typescript and have object orientation in its classical form (see more).
Completion
I consider that the language can be called object-oriented, I think most people think so. It makes little practical difference to know this, but it’s useful information that can help you better understand what you’re doing, which I always stand for.
It can be used object-oriented and not object-oriented.
– PauloHDSousa
@Paulohdsousa Just because there are no classes? I don’t like the orientation to objects via prototypes (Javascript case), but it is possible to argue that it is purest than class-based object orientation. Object inherits from object, for example.
– Pablo Almeida
@Pablo Almeida ok, so she is only object oriented.
– PauloHDSousa
Related: http://answall.com/questions/108548/existe-classe-em-javascript
– Pablo Almeida