Let's create the bike-detail component:
- Open ./Client/src/pages/bikes/bike-detail/bike-detail.component.ts and add the following imports, right after the core import:
import { ActivatedRoute } from '@angular/router'; // App imports import { Bike } from '../bike'; import { BikesService } from '../_services/bikes.service'; import { AuthService } from '../../auth/_services/auth.service'; import { User } from './../../auth/user';
- Add the following properties after the BikeDetailComponent class declaration:
bike: Bike; isLoading: Boolean = false; userVote: number; builders: Array<Object> = [ {id: 1, name: 'Diamond Atelier'}, {id: 2, name: 'Deus Ex Machina\'s'}, {id: 3, name: 'Rough Crafts'}, {id: 4, name: ...