JS

JavaScript ES6 - Default function parameters

21.

How can you define default function parameters in ES6?

By adding a separate line of code to handle the default value inside the function body.

By enclosing the parameter in square brackets.

By using the "default" keyword before the parameter name.

By assigning a default value directly to the parameter.