package annotation
- Alphabetic
- Public
- All
Type Members
-
class
JSBracketAccess extends Annotation with StaticAnnotation
Marks the annotated method as representing bracket access in JavaScript.
Marks the annotated method as representing bracket access in JavaScript.
- See also
-
class
JSBracketCall extends Annotation with StaticAnnotation
Marks the annotated method as representing bracket call in JavaScript.
Marks the annotated method as representing bracket call in JavaScript.
- See also
-
class
JSExport extends Annotation with StaticAnnotation
Specifies that the given entity should be exported for use in JS.
Specifies that the given entity should be exported for use in JS.
- Annotations
- @field() @getter() @setter()
- See also
-
class
JSExportAll extends Annotation with StaticAnnotation
Exports all public members directly defined in a class / object.
Exports all public members directly defined in a class / object.
Strictly equivalent to putting JSExport on every public member. Note: You are allowed to export protected members, but you'll have to do this explicitly on each member.
-
class
JSExportStatic extends Annotation with StaticAnnotation
Specifies that the annotated member should be exported as a JavaScript static member of the companion class.
Specifies that the annotated member should be exported as a JavaScript static member of the companion class.
This annotation may only be used on members of a Scala
object
whose companion class is a non-native JS class. The annotated member will be available as a static member of the companion class.- Annotations
- @field() @getter() @setter()
- See also
-
class
JSExportTopLevel extends Annotation with StaticAnnotation
Specifies that the given member should be exported to the top level of the module.
Specifies that the given member should be exported to the top level of the module.
- Annotations
- @field() @getter() @setter()
- See also
-
class
JSGlobal extends Annotation with StaticAnnotation
Marks the annotated class or object as being a member of the JavaScript global scope.
Marks the annotated class or object as being a member of the JavaScript global scope.
The annotated class/object must also be annotated with
@js.native
, and therefore extend js.Any.Given:
@js.native @JSGlobal class Foo extends js.Object @js.native @JSGlobal("Foobar") object Bar extends js.Object @js.native @JSGlobal("Lib.Babar") class Babar extends js.Object
The following mappings apply (
global
denotes the global scope):Scala.js | JavaScript ------------------------+------------------ new Foo() | new global.Foo() Bar | global.Foobar js.constructorOf[Babar] | global.Lib.Babar
- Annotations
- @field() @getter() @setter()
- See also
-
class
JSGlobalScope extends Annotation with StaticAnnotation
Marks the annotated object as representing the JavaScript global scope.
Marks the annotated object as representing the JavaScript global scope.
This is particularly useful to model top-level functions and fields that are in the JavaScript global scope. They can be declared inside an object annotated with
@JSGlobalScope
.- See also
-
class
JSImport extends Annotation with StaticAnnotation
Marks the annotated declaration as imported from another JS module.
Marks the annotated declaration as imported from another JS module.
Intuitively, this corresponds to ECMAScript import directives. See the documentation of the various constructors.
- Annotations
- @field() @getter() @setter()
-
class
JSName extends Annotation with StaticAnnotation
Specifies the JavaScript name of an entity.
Specifies the JavaScript name of an entity.
- Annotations
- @field() @getter() @setter()
- See also
-
class
JSOperator extends Annotation with StaticAnnotation
Specifies that the entity is a JavaScript operator.
Specifies that the entity is a JavaScript operator.
Only members whose Scala name corresponds to one of the JavaScript operators can be marked with this annotation.
- Annotations
- @field() @getter() @setter()
- See also
-
class
JavaDefaultMethod extends Annotation with StaticAnnotation
Mark a concrete trait method as a Java default method.
Mark a concrete trait method as a Java default method.
This annotation can be used on concrete trait methods to mark them as Java default methods. This should be used *only* to implement interfaces of the JDK that have default methods in Java.
Otherwise using this annotation is unspecified.