Angular2 Toggling showing and hiding between two elements
Separate content and logic

It is a good practice (recommended by Angular style guidelines) to separate component template and component code.

Move template to an own my-app.component.html file and refer to it via templateUrl property instead of template.

Avoid logic in your template

oneShowing=true,twoShowing=false in and twoShowing=true,oneShowing=false parts are technically logic.
It does need to be in the template, and it should not be there.

my-app.component.html

&lt;button type="button" (click)="displayBoxWithNumber(1)"&gt;1&lt;/button&gt;
&lt;button type="button" (click)="displayBoxWithNumber(2)"&gt;2&lt;/button&gt;


my-app.component.ts

displayBoxWithNumber(boxToShow: number): void {
  this.hideAllBoxes();
  this.displayBox(boxToShow);
}
private hideAllBoxes(): void {
  this.oneShowing = false;
  this.twoShowing = false;
}
private displayBox(boxToShow: number): void {
  if (boxToShow === 1)
    this.oneShowing = true;
  else if (boxToShow === 2)
    this.twoShowing = true;
  else
    throw new Error(`Invalid box number provided ${boxToShow}`);
}


Please notice that the code above is for illustrational purposes in your specific context.
Any more or less real project will use *ngFor directive to iterate over some data source to construct the boxes dynamically.
Something like the code below.
Do not worry if you don't understand it yet.
You'll get there later with a bit of practice.

&lt;div *ngFor="let box of boxeList; boxIndex = index; trackBy: trackByBoxId"&gt;
  &lt;button type="button" (click)="displayBox(box, boxIndex)"&gt; {{ box.number }} &lt;/button&gt;
  &lt;div class="box" *ngIf="isBoxActive(box)"&gt;
    &lt;simple-box-view [value]="box"&gt;&lt;/simple-box-view&gt;
  &lt;/div&gt;
&lt;/div&gt;


Know your tool/language

In typeScript you can initialize class' properties inline (this is the same as setting the values in constructor).
You can also omit the type of the variable it is inferred.
Similarly, if your constructor does not do any work, it can be got rid of.

export class App {
  name: string;
  oneShowing = true;
  twoShowing = false;

  // Methods...
}