@@ -95,16 +95,17 @@ export class ActivityDescriptionComponent implements OnInit {
9595 //gets value from sample file
9696 this . yaml . setURI ( './assets/YAML/meta.yaml' ) ;
9797 // Function sets label data
98+ console . log ( this . perfNow ( ) + 's: meta.yaml fetch' ) ;
9899 this . yaml . getJson ( ) . subscribe ( data => {
99- this . YamlObject = data ;
100- this . GeneralLabels = this . YamlObject [ 'strings' ] [ 'en' ] [ 'labels' ] ;
101- this . KnowledgeLabels =
102- this . YamlObject [ 'strings' ] [ 'en' ] [ 'KnowledgeLabels' ] ;
100+ console . log ( this . perfNow ( ) + 's: meta.yaml' ) ;
101+ console . log ( this . perfNow ( ) + 's: meta.yaml processed' ) ;
103102 } ) ;
104103 //gets value from generated folder
104+ console . log ( this . perfNow ( ) + 's: generated.yaml fetch' ) ;
105105 this . yaml . setURI ( './assets/YAML/generated/generated.yaml' ) ;
106106 // Function sets data
107107 this . yaml . getJson ( ) . subscribe ( data => {
108+ console . log ( this . perfNow ( ) + 's: generated.yaml downloaded' ) ;
108109 this . YamlObject = data ;
109110
110111 var allDimensionNames = Object . keys ( this . YamlObject ) ;
@@ -284,6 +285,7 @@ export class ActivityDescriptionComponent implements OnInit {
284285 ) ;
285286 // console.log("data['teamsEvidence']", data['teamsEvidence']);
286287 this . openall ( ) ;
288+ console . log ( this . perfNow ( ) + 's: generated.yaml processed' ) ;
287289 } ) ;
288290 }
289291
@@ -378,4 +380,8 @@ export class ActivityDescriptionComponent implements OnInit {
378380 element . closeAll ( ) ;
379381 } ) ;
380382 }
383+
384+ perfNow ( ) {
385+ return ( performance . now ( ) / 1000 ) . toFixed ( 3 ) ;
386+ }
381387}
0 commit comments