semantics and guarantees than Scala types (subtypes of AnyRef and
never emitted. As such, all members must be defined with their
right-hand-side being js.native. For forward source
compatibility with the next major version, the class/trait/object itself
should be annotated with @js.native.
In most cases, you should not directly extend this trait, but rather extend
declaration must be annotated with
@ScalaJSDefined. Scala.js-defined JS types
cannot directly extend native JS traits; and Scala.js-defined JS traits
cannot declare concrete term members.
It is not possible to define traits or classes that inherit both from this
trait and a strict subtype of AnyRef. In fact, you should think of
js.Any as a third direct subclass of scala.Any, besides
scala.AnyRef and scala.AnyVal.
interoperability guide of Scala.js for more details.