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 'length' of undefined

See original GitHub issue

I’m submitting a … (check one with “x”)

[x] bug report => search github for a similar issue or PR before submitting
[ ] feature request
[ ] support request => Please do not submit support request here, post on Stackoverflow or Gitter

Current behavior I got many:

ERROR TypeError: Cannot read property ‘length’ of undefined

and everything is broken. This happens in version 11.1.3, but everything is fine in 11.0.4

Expected behavior

should work fine

Reproduction of the problem I’ve just updated to the latest version.

Please tell us about your environment:

  • Table version: the bug happens in 11.1.3, but not in 11.0.4

  • Angular version: 5.0.3

  • Browser: Chrome

  • Language: TypeScript 2.4.2

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:9 (3 by maintainers)

github_iconTop GitHub Comments

3reactions
petterhoelcommented, Nov 24, 2017

@amcdnl Did a quick test and seems it errs when initial state is an unassigned variable. This might be expected behaviour? badRows: Item[]; // <- will err goodRows: Item[] = []; // <- smooth sailing

Checked 11.1.3 & 11.1.4

0reactions
FrancescoBorzicommented, Jan 8, 2018

I tried version 11.1.7 and the issue seems to be now solved

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot read properties of undefined (reading 'length') - TrackJS
This message indicates that our code expects to have an object with a length property, but that object was not present. length is...
Read more >
ERROR TypeError: Cannot read property 'length' of undefined
I got stuck in a similar situation where even after assigning results as an array ( as shown below ), the error persisted....
Read more >
Typeerror: Cannot Read Property 'length' of Undefined
A typeerror length of undefined can indicate that the actual type of an operand is different from the expected type. This error can...
Read more >
[SOLVED] Cannot Read Property 'length' of Undefined in JS
To fix the “cannot read property 'length' of undefined” error, perform an undefined check on the variable before accessing the length property ......
Read more >
TypeError: Cannot read property 'length' of Undefined in JS
The "Cannot read property 'length' of undefined" error occurs when accessing the length property on an undefined value. To solve the error, make...
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