let arr = [
[10, 2],
["a",3],
[2.2, "d","h",6,"s",14,1],
["f", "e"],
["p","y","z","V"],
[5]
]
let val = arr.flat()
val = [
...val.filter(v => typeof v === "number").sort((a, b) => a - b),
...val.filter(v => typeof v === "string").sort()
]
console.log(val)