Skip to content

Instantly share code, notes, and snippets.

@buildmotion
Created March 22, 2018 04:21
Show Gist options
  • Save buildmotion/03114f17f957c33dcb8dbfa2ce652889 to your computer and use it in GitHub Desktop.
Save buildmotion/03114f17f957c33dcb8dbfa2ce652889 to your computer and use it in GitHub Desktop.
import { Component } from '@angular/core';
import {NgbModal, NgbActiveModal } from '@ng-bootstrap/ng-bootstrap';
import { ModalComponent } from './modal/modal.component';
import { ModalAboutComponent } from './modal-about/modal-about.component';
@Component({
selector: 'app-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css']
})
export class AppComponent {
title = 'app';
constructor(private modalService: NgbModal) {}
open() {
// const modalRef = this.modalService.open(ModalComponent);
const modalRef = this.modalService.open(ModalAboutComponent);
modalRef.componentInstance.title = 'About';
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment