What do you want to save?
Add Code snippet
New code examples
-
Javascript 2021-11-05 06:37:07
c# is json valid
private static bool IsValidJson(string strInput) { if (string.IsNullOrWhiteSpace(strInput)) { return false;} strInput = strInput.Trim(); if ((strInput.StartsWith("{") && strInput.EndsWith("}")) || //For object ... Add solution -
-
Javascript 2021-11-02 05:31:15
get largest no in the array javascript
//For Values var arr =[1,10,3] var min = Math.min.apply(null, arr), max = Math.max.apply(null, arr); //For Objects var arr = [{a: 1},{a: 10},{a: 3}] var values = arr.map(val => val.a); var max = Math.max.apply(null, values); console.log(max) Add solution -
Javascript 2021-10-21 15:06:13
ellipses in js
function sum(x, y, z) { return x + y + z; } const numbers = [1, 2, 3]; console.log(sum(...numbers)); // expected output: 6 console.log(sum.apply(null, numbers)); // expected output: 6 /* Spread syntax (...) allows an iterable such as an array expres... Add solution -
Javascript 2021-10-19 19:31:03
what is ... in javascript
function sum(x, y, z) { return x + y + z; } const numbers = [1, 2, 3]; console.log(sum(...numbers)); // expected output: 6 console.log(sum.apply(null, numbers)); // expected output: 6 /* Spread syntax (...) allows an iterable such as an array expres... Add solution -
Html 2021-10-02 13:51:03
class
Class is a blueprint or template which you can create as many objects as you like. Object is a member or instance of a class. Class is declared using class keyword, Object is created through new keyword mainly. A class is a template for objects. A class ... Add solution -
Javascript 2021-10-01 10:17:04
store data in browser javascript
// localStorage for objects, arrays or any data type var obj = { firstName: "Bob", lastName: "Jeff", age: 13 } localStorage.setItem("itemname", JSON.stringify(obj)); // Save the obj as string var item = JSON.parse(lo... Add solution -
Javascript 2021-10-01 05:58:02
trailing comma javascript
Trailing commas (sometimes called "final commas") can be useful when adding new elements, parameters, or properties to JavaScript code. If you want to add a new property, you can simply add a new line without modifying the previously last line i... Add solution -
TypeScript 2021-09-17 02:11:02
Javascript:
/* Spread syntax ( ex. ...arrayName) allows an iterable such as an array expression or string to be expanded in places where zero or more arguments (for function calls) elements (for array literals) are expected, or an object expression to be expanded ... Add solution
Best helpers
User 768576
+10
Viki
+5
Riptiki
+5
Suraj tiwari
+5
Johnno Nolan
+5
Alxna
+5
Bmcl
+5
Nuno
+5
AllenG
+5
Hong
+5
Hugh Zang
+5
Marcel Souza
+5
Rosey28
+5