Skip to content

Commit 69deb23

Browse files
author
Moreno Bruschi
committedNov 12, 2019
feat(header): added application version label next to the title
Add version label next to title Closes issue #2
1 parent 9b5fd7b commit 69deb23

File tree

3 files changed

+4
-1
lines changed

3 files changed

+4
-1
lines changed
 

‎src/app/core/components/header/header.component.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<div class="d-md-flex justify-content-between align-items-center">
2-
<h1 class="h3"><img src="assets/redis-white.png" />{{title}}</h1>
2+
<h1 class="h3"><img src="assets/redis-white.png" />{{title}} {{version}}</h1>
33
<nav>
44
<ul class="nav">
55
<li class="nav-item">

‎src/app/core/components/header/header.component.ts

+2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import { Component, ChangeDetectorRef, AfterViewInit } from '@angular/core';
2+
import { version } from '../../../../../package.json';
23

34
@Component({
45
selector: 'tr-header',
@@ -19,6 +20,7 @@ import { Component, ChangeDetectorRef, AfterViewInit } from '@angular/core';
1920
})
2021
export class HeaderComponent implements AfterViewInit {
2122
title = 'Redis Patterns';
23+
version = version;
2224

2325
constructor(private changeDetectorRef: ChangeDetectorRef) {}
2426

‎tsconfig.json

+1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
"emitDecoratorMetadata": true,
1111
"experimentalDecorators": true,
1212
"importHelpers": true,
13+
"resolveJsonModule": true,
1314
"target": "es2015",
1415
"typeRoots": [
1516
"node_modules/@types"

0 commit comments

Comments
 (0)
Please sign in to comment.