Sort Score
Result 10 results
Languages All
Labels All
Results 51 - 60 of 22,098 for

js

(0.07 sec)
  1. function - JavaScript | MDN

    The function declaration creates a binding of a new function to a given name.... Try it Syntax js function name(param0) { statements...inconsistent across implementations. js console.log( `'foo' name ${ "foo"...

    developer.mozilla.org/en-US/docs/Web/JavaScript...
  2. Less than or equal (<=) - JavaScript | MDN

    The less than or equal (<=) operator returns true if the left operand is less than or equal to the right operand, and false otherwise.... Try it Syntax js x <= y Description The operands...Examples String to string comparison js "a" <= "b"; // true "a" <= "a";...

    developer.mozilla.org/en-US/docs/Web/JavaScript...
  3. Division (/) - JavaScript | MDN

    The division (/) operator produces the quotient of its operands where the left operand is the dividend and the right operand is the divisor.... Try it Syntax js x / y Description The / operator...Examples Division using numbers js 1 / 2; // 0.5 Math.floor(3 /...

    developer.mozilla.org/en-US/docs/Web/JavaScript...
  4. Conditional (ternary) operator - JavaScript | MDN

    The conditional (ternary) operator is the only JavaScript operator that takes three operands: a condition followed by a question mark (?), then an expression to execute if the condition is truthy followed by a colon (:), and finally the expression to execute if the condition is falsy. This operator is frequently used as an alternative to an if...else statement.... Try it Syntax js condition ? exprIfTrue : exprIfFalse...exprIfFalse . Examples A basic example js const age = 26; const beverage...

    developer.mozilla.org/en-US/docs/Web/JavaScript...
  5. Public class fields - JavaScript | MDN

    Public fields are writable, enumerable, and configurable properties. As such, unlike their private counterparts, they participate in prototype inheritance.... Syntax js class ClassWithField { instanceField;...field names may be computed. js const PREFIX = "prefix"; class...

    developer.mozilla.org/en-US/docs/Web/JavaScript...
  6. Default parameters - JavaScript | MDN

    Default function parameters allow named parameters to be initialized with default values if no value or undefined is passed.... Try it Syntax js function fnName(param1 = defaultValue1...and multiply would return NaN . js function multiply(a, b) { return...

    developer.mozilla.org/en-US/docs/Web/JavaScript...
  7. Background scripts - Mozilla | MDN

    Background scripts or a background page enable you to monitor and react to events in the browser, such as navigating to a new page, removing a bookmark, or closing a tab....js"], "persistent": false, "type":...type="module" src="background-script.js"></script> </head> </html> You...

    developer.mozilla.org/en-US/docs/Mozilla/Add-on...
  8. The arguments object - JavaScript | MDN

    arguments is an array-like object accessible inside functions that contains the values of the arguments passed to that function....you can access them as follows: js arguments[0]; // first argument...and returns the longest one: js function longestString() { let...

    developer.mozilla.org/en-US/docs/Web/JavaScript...
  9. Backreference: \1, \2 - JavaScript | MDN

    A backreference refers to the submatch of a previous capturing group and matches the same text as that group. For named capturing groups, you may prefer to use the named backreference syntax.... js /(b)\1/i.test("bB"); // true...groups, a syntax error is thrown. js /(a)\2/u; // SyntaxError: Invalid...

    developer.mozilla.org/en-US/docs/Web/JavaScript...
  10. SyntaxError: arguments is not valid in fields -...

    The JavaScript exception "SyntaxError: arguments is not valid in fields" occurs when the arguments identifier is read in a class field initializer or in a static initialization block, outside of a non-arrow function.... Examples js function makeOne() { class C...in fields } return new C(); } js let CArgs; class C { static {...

    developer.mozilla.org/en-US/docs/Web/JavaScript...