OiO.lk Community platform!

Oio.lk is an excellent forum for developers, providing a wide range of resources, discussions, and support for those in the developer community. Join oio.lk today to connect with like-minded professionals, share insights, and stay updated on the latest trends and technologies in the development field.
  You need to log in or register to access the solved answers to this problem.
  • You have reached the maximum number of guest views allowed
  • Please register below to remove this limitation

findLastIndex is not a function,how,why

  • Thread starter Thread starter Shylock Wu
  • Start date Start date
S

Shylock Wu

Guest
Code:
const list = [1,2,100,50,100,20]
const index = list.findLastIndex((item)=>item===100)
console.log(index)
// TypeError: list.findLastIndex is not a function

Can we say that this method does not exist, but it does exist in MDN

<pre class="lang-js prettyprint-override"><code>const list = [1,2,100,50,100,20]
const index = list.findLastIndex((item)=>item===100)
console.log(index)
// TypeError: list.findLastIndex is not a function
</code></pre>
<p><strong>Can we say that this method does not exist, but it does exist in MDN</strong></p>
 
Top