question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ERROR TypeError: Cannot read property 'isEventFrom'

See original GitHub issue

Bug description:

Hello world. since i update the version of ng boostrap from 1.0.0 to 1.1.2 I have an error in my web console.

image

Link to minimally-working plunker that reproduces the issue:

I have issue on this piece of code:

<div ngbDropdown class="dropdown" #myDropGlobal="ngbDropdown">and <div ngbDropdown class="dropdown"> wich seems good.

Version of Angular, ng-bootstrap, and Bootstrap:

Angular: 5

ng-bootstrap: 1.1.2

Bootstrap: 4.0.0-beta

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:15 (2 by maintainers)

github_iconTop GitHub Comments

8reactions
MariMaxcommented, Apr 26, 2018

@pkozlowski-opensource thanks for the clarification, in our case ngbDropdownToggle was available only after ngbDropdown was created, wrong code snippet bellow

      <div ngbDropdown>
        <button ngbDropdownToggle *ngIf="showButton()">Btn</button>
        <ul ngbDropdownMenu>
          <li *ngFor="let item of items">
            <button (click)="actionOnItem(item)">{{item.name}}</button>
          </li>
        </ul>
      </div>
3reactions
sscotscommented, May 15, 2018

I’ve determined the error appears when applying an *ngIf to the “ngbDropdownToggle” element

Read more comments on GitHub >

github_iconTop Results From Across the Web

ERROR TypeError: Cannot read property 'isEventFrom' of ...
I've build ng-bootstrap modal, which works with problems, but it works at least. but whenever I open the website (doesn't matter which page) ......
Read more >
autocomplete - error: Cannot read property 'title' of nul
Dear supporter, We are using autocomplete in our Angular 5 project. Unfortunately, we got the following error. null: ERROR null: TypeError: Cannot read...
Read more >
Angular Test - Cannot read property 'textContent' of null
Getting Started with Angular - Angular Test - Karma server TypeError : Cannot read property 'textContent' of nullSpecial offers & Free ...
Read more >
ANGULAR 13 TypeError Cannot read property of undefined
In this tutorial, we will see a most common error faced by the Angular developers named as " TypeError Cannot read property of...
Read more >
ERROR TypeError: Cannot read properties of undefined ...
You're trying to read the property 'page' of 'this.paginator'. 'this.paginator' doesn't appear to be defined anywhere in your code, and as the ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found