Skip to content

Instantly share code, notes, and snippets.

@sajeetharan
Created April 20, 2017 19:28
Show Gist options
  • Save sajeetharan/185cc0d6839eee3479a9505ea3c0167e to your computer and use it in GitHub Desktop.
Save sajeetharan/185cc0d6839eee3479a9505ea3c0167e to your computer and use it in GitHub Desktop.
user listing.ts
import { Component, ViewChild, AfterViewInit } from '@angular/core';
import { ListingContainerComponent } from './listing-container/listing-container.component';
@Component({
moduleId: module.id,
templateUrl: 'user-listings.component.html'
})
export class UserListingsComponent implements AfterViewInit {
@ViewChild(ListingContainerComponent) listingContainerComponent: ListingContainerComponent;
private lengthofAllListings: number;
constructor() {
}
ngAfterViewInit() {
this.lengthofAllListings = this.listingContainerComponent.countofAll;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment