list.to()
The list.to() function returns $list with elements from the first index to the given $to index.
// Functions.
@use 'list.nth.function';
// Modules.
@use '../number';
// The `list.to()` function.
@function to($list, $to) {
@return list.nth($list, number.range(0, $to) or $to...);
}https://github.com/angular-package/sass/blob/main/list/_list.to.function.scss
Parameters
$list
$list The list to get the elements from 1 to given $to.
$to
$toIndex of the last element to retrieve from $list.
Return
The return value is the list of the elements from 1 to given $to index.
Examples
Last updated
Was this helpful?