Intl.ListFormat
Input
nb
Alternativ use
Intl.ListFormat can also be used from Array.prototype.toLocaleString()
["Miso", "Sesam", "Mami"]
.toLocaleString("nb")
Miso, Sesam og Mami
Output
type
{
type: "conjunction"
}
Miso, Sesam og Mami
{
type: "disjunction"
}
Miso, Sesam eller Mami
{
type: "unit"
}
Miso, Sesam og Mami
style
{
style: "long"
}
Miso, Sesam og Mami
{
style: "short"
}
Miso, Sesam og Mami
{
style: "narrow"
}
Miso, Sesam og Mami
localeMatcher
{
localeMatcher: "best fit"
}
Miso, Sesam og Mami
{
localeMatcher: "lookup"
}
Miso, Sesam og Mami
conjunction + style
{
type: "conjunction",
style: "long"
}
Miso, Sesam og Mami
{
type: "conjunction",
style: "short"
}
Miso, Sesam og Mami
{
type: "conjunction",
style: "narrow"
}
Miso, Sesam og Mami
disjunction + style
{
type: "disjunction",
style: "long"
}
Miso, Sesam eller Mami
{
type: "disjunction",
style: "short"
}
Miso, Sesam eller Mami
{
type: "disjunction",
style: "narrow"
}
Miso, Sesam eller Mami
unit + style
{
type: "unit",
style: "long"
}
Miso, Sesam og Mami
{
type: "unit",
style: "short"
}
Miso, Sesam, Mami
{
type: "unit",
style: "narrow"
}
Miso, Sesam, Mami