Skip to content

Commit f1a4783

Browse files
authored
Merge pull request #3 from actionanand/features/1-http-feature
colorful console messages
2 parents 2402563 + 36664f3 commit f1a4783

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

Diff for: README.md

+1
Original file line numberDiff line numberDiff line change
@@ -231,3 +231,4 @@ To configure the pre-commit hook, simply add a `precommit` npm script. We want t
231231
232232
- [GitHub Actions for Angular](https://github.com/rodrigokamada/angular-github-actions)
233233
- [Angular 16 - milestone release](https://github.com/actionanand/ng16-signal-milestone-release)
234+
- [Colorful Console Message](https://www.samanthaming.com/tidbits/40-colorful-console-message/)

Diff for: src/app/app.component.ts

+12-1
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,15 @@ import { UserPlacesComponent } from './places/user-places/user-places.component'
1010
styleUrl: './app.component.css',
1111
imports: [AvailablePlacesComponent, UserPlacesComponent],
1212
})
13-
export class AppComponent {}
13+
export class AppComponent {
14+
styles = ['color: indigo', 'background: #90EE90', 'font-weight: bold', 'font-size: 18px'].join(';');
15+
16+
constructor() {
17+
console.log(
18+
'%cUse local setup by cloning the project to see it in full power with backend api calls.',
19+
'color: green; background: yellow; font-size: 23px',
20+
);
21+
console.log('%c%s', this.styles, `git clone https://github.com/actionanand/angular-http-project.git`);
22+
console.log('GitHub Location: ' + 'https://github.com/actionanand/angular-http-project');
23+
}
24+
}

0 commit comments

Comments
 (0)