Published
Edited
Feb 7, 2020
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
"You have just queried " + apiReturn.apiName + " and receieved response code " + apiReturn.apiCode + ". The API Wizard says that " + apiReturn.apiReturnBody + ". The Wizard states that you shall pay " + apiReturn.apiPaymentAsked + " or guess the wizard's name."
Insert cell
Insert cell
`You have just queried ${apiReturn.apiName} and receieved response code ${apiReturn.apiCode}. The API Wizard says that ${apiReturn.apiReturnBody}. The Wizard states that you shall pay ${apiReturn.apiPaymentAsked} or guess the wizard's name.`
Insert cell
Insert cell
Insert cell
Insert cell
ccNumber= 112358132134
Insert cell
`Your CC number is: ${ccNumber.toString().slice(-4).padStart(ccNumber.toString().length, '*')}`
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
{
var a1,a2,a3,a4,a5;
[a1,a2,a3,a4,a5] = array
return `
a1= ${a1},
a2= ${a2},
a3= ${a3},
a4= ${a4},
a5= ${a5}
`
}
Insert cell
{
var { bob, your, but, is, a } = obj //this is a valid syntax if you don't want to declare the variables separately...
return `
bob= ${bob},
your= ${your}
but= ${but}
is= ${is}
a= ${a}
`
}
Insert cell
Insert cell
{
var bob, rest;
( { bob, ...rest } = obj )
return `Bob: ${bob}, everything else: ${JSON.stringify(rest)}`
}
Insert cell
{ //because strings are just arrays...
var start, rest;
([start, ...rest] = str)
return start + "/" + rest
}
Insert cell
{
var start, rest;
([start, ...rest] = array)
return start + "/" + rest
}
Insert cell
Insert cell

One platform to build and deploy the best data apps

Experiment and prototype by building visualizations in live JavaScript notebooks. Collaborate with your team and decide which concepts to build out.
Use Observable Framework to build data apps locally. Use data loaders to build in any language or library, including Python, SQL, and R.
Seamlessly deploy to Observable. Test before you ship, use automatic deploy-on-commit, and ensure your projects are always up-to-date.
Learn more