From f9fa09b5311d77e22ccadee716353c94fa293eb3 Mon Sep 17 00:00:00 2001 From: Priyansh Date: Sat, 22 Jan 2022 20:32:53 -0500 Subject: docs: rangeIndex() method --- README.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/README.md b/README.md index 99395dc..c58c594 100644 --- a/README.md +++ b/README.md @@ -284,6 +284,17 @@ Data Types: string(26), number(8), object(1), undefined(1) Memory Usage: 550 bytes ``` +### `rangeIndex()` ![](https://img.shields.io/badge/not%20chainable-red.svg?style=plastic) + +The `rangeIndex()` method is used to get the element at a particular index if the complete data was flattened. It takes an index as an argument. Index is zero-based. + +`rangeIndex()` does not return a new frame and therefore it is not chainable. It returns the element at the index and therefore a `console.log` is required to print the element. + +```js +// get the element at index 2 +console.log(frame.rangeIndex(2)); +``` + ## Helper Methods Helper methods are methods that are used to help you with some common tasks. They are not chainable. They are not required to use the frame methods. -- cgit v1.2.3