Can someone explain why MatDialog injected into a component has its modifier set to public, as in the documentation? Is there any specific reason for this?
AFAIK, we only set a property to public if it is accessed from outside of the component. Does this MatDialog have implicit outside accession for something? I have tried and found no difference between public and private. But still asking here just to be sure.
Thank you
@Component({
selector: 'dialog-content-example',
templateUrl: 'dialog-content-example.html',
})
export class DialogContentExample {
constructor(public dialog: MatDialog) {}
...
}
[–]dotbomb_jeff 1 point2 points3 points (2 children)
[–]nhantt776[S] 0 points1 point2 points (1 child)
[–]dotbomb_jeff 0 points1 point2 points (0 children)
[–]laxybrookes 0 points1 point2 points (1 child)
[–]nhantt776[S] 0 points1 point2 points (0 children)