Skip to content

Angular1 | Tabbar issue: Uncaught TypeError: el._show is not a function #2307

Closed
@keijiodagawa

Description

@keijiodagawa

Environment

When setting "ons-tabbar" on "ons-tab" page, the following error message will be displayed. (Onsen UI 2.6.0 or later)

Uncaught TypeError: el._show is not a function

[Core]
  onsenui latest
  
[Framework]
  angular1 1.5.8

[Framework binding]
 angular1-onsenui latest

[Platform]
  All

[Browser]
  All

Encountered problem

How to reproduce

Demo link

  • HTML
<ons-page ng-controller="AppController as app">
  <ons-toolbar>
    <div class="center">My App</div>
  </ons-toolbar>

  <ons-tabbar position="auto">
    <ons-tab page="page1.html" label="Page 1" icon="square" active></ons-tab>
    <ons-tab page="page2.html" label="Page 2" icon="square"></ons-tab>
  </ons-tabbar>
</ons-page>

<ons-template id="page1.html">
  <ons-page>
    <div class="content" style="text-align: center">
      <ons-tabbar position="top">
        <ons-tab page="page1-1.html" label="Page 1-1" icon="square" active></ons-tab>
        <ons-tab page="page2-1.html" label="Page 2-1" icon="square"></ons-tab>
      </ons-tabbar>
    </div>
  </ons-page>
</ons-template>

<ons-template id="page2.html">
  <ons-page>
    <div class="content" style="text-align: center">
      <p>Page 2 content</p>
    </div>
  </ons-page>
</ons-template>

<ons-template id="page1-1.html">
  <ons-page>
    <div class="content" style="text-align: center">
      <p>page1-1 content</p>
    </div>
  </ons-page>
</ons-template>

<ons-template id="page2-1.html">
  <ons-page>
    <div class="content" style="text-align: center">
      <p>page2-1 content</p>
    </div>
  </ons-page>
</ons-template>
  • JS
ons.bootstrap()
  .controller('AppController', function() {
  });

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions