File tree Expand file tree Collapse file tree 8 files changed +109
-0
lines changed
Expand file tree Collapse file tree 8 files changed +109
-0
lines changed Original file line number Diff line number Diff line change 1+ var Pages ;
2+ ( function ( Pages ) {
3+ var LoginPage = ( function ( ) {
4+ function LoginPage ( container ) {
5+ var _this = this ;
6+ container . on ( "click" , ".login-link" , function ( item ) {
7+ _this . login ( ) ;
8+ } ) ;
9+ container . on ( "click" , ".login-link" , function ( item ) {
10+ this . login ( ) ;
11+ } ) ;
12+ }
13+ LoginPage . prototype . login = function ( ) {
14+ console . log ( "logged in" ) ;
15+ } ;
16+ return LoginPage ;
17+ } ) ( ) ;
18+ Pages . LoginPage = LoginPage ;
19+ } ) ( Pages || ( Pages = { } ) ) ;
Original file line number Diff line number Diff line change 1+ module Pages {
2+ export class LoginPage {
3+ constructor ( container : JQuery ) {
4+ container . on ( "click" , ".login-link" , ( item ) => {
5+ this . login ( ) ;
6+ } ) ;
7+ container . on ( "click" , ".login-link" , function ( item ) {
8+ this . login ( ) ;
9+ } ) ;
10+ }
11+
12+ login ( ) {
13+ console . log ( "logged in" ) ;
14+ }
15+ }
16+ }
Original file line number Diff line number Diff line change 1+ var Castle = ( function ( ) {
2+ function Castle ( name ) {
3+ this . name = name ;
4+ }
5+ Castle . prototype . Build = function ( ) {
6+ console . log ( "Castle built: " + this . name ) ;
7+ } ;
8+ return Castle ;
9+ } ) ( ) ;
Original file line number Diff line number Diff line change 1+ class Castle {
2+ constructor ( public name ) {
3+ }
4+ public Build ( ) {
5+ console . log ( "Castle built: " + this . name ) ;
6+ }
7+ }
Original file line number Diff line number Diff line change 1+ var __extends = this . __extends || function ( d , b ) {
2+ for ( var p in b ) if ( b . hasOwnProperty ( p ) ) d [ p ] = b [ p ] ;
3+ function __ ( ) { this . constructor = d ; }
4+ __ . prototype = b . prototype ;
5+ d . prototype = new __ ( ) ;
6+ } ;
7+ var Westros ;
8+ ( function ( Westros ) {
9+ ( function ( Buildings ) {
10+ var BaseStructure = ( function ( ) {
11+ function BaseStructure ( ) {
12+ console . log ( "Structure built" ) ;
13+ }
14+ return BaseStructure ;
15+ } ) ( ) ;
16+ Buildings . BaseStructure = BaseStructure ;
17+
18+ var Castle = ( function ( _super ) {
19+ __extends ( Castle , _super ) ;
20+ function Castle ( name ) {
21+ _super . call ( this ) ;
22+ this . name = name ;
23+ }
24+ Castle . prototype . Build = function ( ) {
25+ console . log ( "Castle built: " + this . name ) ;
26+ } ;
27+ return Castle ;
28+ } ) ( BaseStructure ) ;
29+ Buildings . Castle = Castle ;
30+ } ) ( Westros . Buildings || ( Westros . Buildings = { } ) ) ;
31+ var Buildings = Westros . Buildings ;
32+ } ) ( Westros || ( Westros = { } ) ) ;
Original file line number Diff line number Diff line change 1+ module Westros . Buildings {
2+ export class BaseStructure {
3+ constructor ( ) {
4+ console . log ( "Structure built" ) ;
5+ }
6+ }
7+
8+ export class Castle extends BaseStructure {
9+ constructor ( public name ) {
10+ super ( ) ;
11+ }
12+ public Build ( ) {
13+ console . log ( "Castle built: " + this . name ) ;
14+ }
15+ }
16+ }
Original file line number Diff line number Diff line change 1+ var numbers = [ ] ;
2+ numbers . push ( 7 ) ;
3+ numbers . push ( 9 ) ;
4+ var unknown = numbers . pop ( ) ;
5+ console . log ( unknown . substr ( 0 , 1 ) ) ;
Original file line number Diff line number Diff line change 1+ var numbers : Array < number > = [ ] ;
2+ numbers . push ( 7 ) ;
3+ numbers . push ( 9 ) ;
4+ var unknown = numbers . pop ( ) ;
5+ console . log ( unknown . substr ( 0 , 1 ) ) ;
You can’t perform that action at this time.
0 commit comments