UNPKG

@base-ui-components/react

Version:

Base UI is a library of headless ('unstyled') React components and low-level hooks. You gain complete control over your app's CSS and accessibility features.

16 lines (15 loc) 302 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.setValueIndex = setValueIndex; var _asc = require("./asc"); function setValueIndex({ values, newValue, index }) { const output = values.slice(); output[index] = newValue; return output.sort(_asc.asc); }