Skip to content

colorful console messages #3

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -231,3 +231,4 @@ To configure the pre-commit hook, simply add a `precommit` npm script. We want t

- [GitHub Actions for Angular](https://github.com/rodrigokamada/angular-github-actions)
- [Angular 16 - milestone release](https://github.com/actionanand/ng16-signal-milestone-release)
- [Colorful Console Message](https://www.samanthaming.com/tidbits/40-colorful-console-message/)
13 changes: 12 additions & 1 deletion src/app/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,15 @@ import { UserPlacesComponent } from './places/user-places/user-places.component'
styleUrl: './app.component.css',
imports: [AvailablePlacesComponent, UserPlacesComponent],
})
export class AppComponent {}
export class AppComponent {
styles = ['color: indigo', 'background: #90EE90', 'font-weight: bold', 'font-size: 18px'].join(';');

constructor() {
console.log(
'%cUse local setup by cloning the project to see it in full power with backend api calls.',
'color: green; background: yellow; font-size: 23px',
);
console.log('%c%s', this.styles, `git clone https://github.com/actionanand/angular-http-project.git`);
console.log('GitHub Location: ' + 'https://github.com/actionanand/angular-http-project');
}
}