how to add a variable in js
var x = 5; // assign the value 5 to x
how to add a variable in js
var x = 5; // assign the value 5 to x
how to add a variable in js
var x = 5; // assign the value 5 to x
how to assign variables in javascript
// data from json: resp = {"home": 1, "landmark": 2}
// Method 1:
// use ` for add variable
url = `workspace/detail/${resp.home}`;
console.log(url) -> // workspace/detail/1
// Method 2:
// use ' and + for concentrace variable
url = 'workspace/detail/' + resp.home;
console.log(url) -> // workspace/detail/1
how to create a variable in javascript
// you an pass in strings or a number
var exampleVariable = 'Example string' // this is a normal string
var anotherExample = 839;
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us