Files
test/src/helpers/getConfidence.js
T

12 lines
299 B
JavaScript
Raw Normal View History

2024-10-12 02:08:44 +03:00
const getConfidence = (media, breakpoint) => {
const best = Object.values(media)
.filter((med) => med.found)
.reduce((prev, current) => {
return prev.metric > current.metric ? prev : current;
});
return best.confidence;
};
export default getConfidence;