Skip to content

Commit 078f2c5

Browse files
author
exoego
committed
Locales is optional and options can be passed when locales is undefined
1 parent 3ad597c commit 078f2c5

File tree

1 file changed

+3
-3
lines changed
  • src/main/scala/org/scalajs/dom/experimental/intl

1 file changed

+3
-3
lines changed

src/main/scala/org/scalajs/dom/experimental/intl/Intl.scala

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ class Collator(locales: js.UndefOr[String | js.Array[String]] = js.undefined,
3535
*/
3636
@js.native
3737
@JSGlobal("Intl.DateTimeFormat")
38-
class DateTimeFormat(locales: String | js.Array[String],
38+
class DateTimeFormat(locales: js.UndefOr[String | js.Array[String]] = js.undefined,
3939
options: js.UndefOr[DateTimeFormatOptions] = js.undefined)
4040
extends js.Object {
4141
def format(date: js.Date): String = js.native
@@ -52,8 +52,8 @@ class DateTimeFormat(locales: String | js.Array[String],
5252
*/
5353
@js.native
5454
@JSGlobal("Intl.NumberFormat")
55-
class NumberFormat(locales: String | js.Array[String],
56-
options: js.UndefOr[NumberFormatOptions])
55+
class NumberFormat(locales: js.UndefOr[String | js.Array[String]] = js.undefined,
56+
options: js.UndefOr[NumberFormatOptions] = js.undefined)
5757
extends js.Object {
5858
def format(number: Double): String = js.native
5959
def resolvedOptions(): NumberFormatOptions = js.native

0 commit comments

Comments
 (0)