File tree Expand file tree Collapse file tree 2 files changed +13
-6
lines changed
templates/app/client/app/main Expand file tree Collapse file tree 2 files changed +13
-6
lines changed Original file line number Diff line number Diff line change @@ -49,12 +49,19 @@ export class Base extends YoBase {
4949 to ( ) {
5050 return this . filters . expect ? ').to' : '.should' ;
5151 }
52+
53+ public ( ) {
54+ return this . filters . ts ? 'public ' : '' ;
55+ }
56+ private ( ) {
57+ return this . filters . ts ? 'private ' : '' ;
58+ }
5259}
5360
5461export class NamedBase extends Base {
5562 constructor ( ...args ) {
5663 super ( ...args ) ;
57-
64+
5865 this . argument ( 'name' , { type : String , required : true } ) ;
5966
6067 var name = this . name . replace ( / \/ / g, '-' ) ;
Original file line number Diff line number Diff line change @@ -8,18 +8,18 @@ import { SocketService } from '../../components/socket/socket.service';
88 styles : [ require ( './main.<%=styleExt%>' ) ] ,
99} )
1010export class MainComponent implements OnInit < % if ( filters . socketio ) { % > , OnDestroy < % } % > {
11- Http ;
1211 < % _ if ( filters . socketio ) { - % >
1312 SocketService ; < % } % >
1413 awesomeThings = [ ] ;
1514 < % _ if ( filters . models ) { - % >
1615 newThing = '' ; < % } % >
1716
18- static parameters = [Http, SocketService];
19- constructor(_Http_: Http< % if ( filters . socketio ) { % > , _SocketService_: SocketService< % } % > ) {
20- this . Http = _Http_ ;
17+ < % _ if ( filters . babel ) { - % >
18+ static parameters = [ Http , SocketService ] ; < % } % >
19+ constructor(< %= private ( ) % > http: Http< % if ( filters . socketio ) { % > , < %= private ( ) % > socketService: SocketService< % } % > ) {
20+ this . Http = http ;
2121 < % _ if ( filters . socketio ) { - % >
22- this . SocketService = _SocketService_ ; < % } %>
22+ this . SocketService = socketService ; < % } %>
2323 }
2424
2525 ngOnInit ( ) {
You can’t perform that action at this time.
0 commit comments