You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
378 B

4 years ago
  1. # `values()`
  2. The values method returns a new collection with the keys reset to consecutive integers:
  3. ```js
  4. const collection = collect({
  5. a: 'xoxo',
  6. b: 'abab',
  7. c: '1337',
  8. 1337: 12,
  9. });
  10. const values = collection.values();
  11. values.all();
  12. // [12, 'xoxo', 'abab', '1337']
  13. ```
  14. [View source on GitHub](https://github.com/ecrmnn/collect.js/blob/master/src/methods/values.js)