Salesforce Javascript Developer I Salesforce Certified JavaScript Developer I Exam Practice Test

Page: 1 / 14
Total 224 questions
Question 1

Refer to the string below:

const str = 'Salesforce';

Which two statements result in the word 'Sales'?

Choose 2 answers



Answer : B, D


Question 2

A developer at Universal Containers is creating their new landing page based on HTML, CSS, and JavaScript.

To ensure that visitors have a good experience, a script named personalizeWebsiteContent needs to be executed when the webpage is fully loaded (HTML content and all related files), in order to do some custom initializations.

Which implementation should be used to call Fe:s:-a;::eHec5;te::.-.ter.: based on the business requirement above?



Answer : C


Question 3

A developer tries to retrieve all cookies, then sets a certain key value pair in the cookie. These statements are used:

What is the behavior?



Answer : C


Question 4

Refer to the code below:

What is the result when the Promise in the execute function is rejected?



Answer : C


Question 5

Refer to the code below:

const car = {

price:100,

getPrice:function(){

return this.price;

}

};

const customCar = Object.create(car);

customCar.price = 70;

delete customCar.price;const result = customCar.getPrice();

Whatis the value of result after the code executes?



Answer : A


Question 6

A developer at Universal Containers is creating their new landing pagebased on HTML, CSS, and JavaScript. The website includes multiple external resources that are loaded when the page is opened.

To ensure that visitors have a good experience, a script named personalizeWebsiteContent needs to be executed when the webpage isloaded and there is no need to wait for the resources to be available.

Which statement should be used to call personalizeWebsiteContent based on the above business requirement?



Answer : A


Question 7

A developer is setting up a Node,js server and is creating a script at the root of the source code, index,js, that will start the server when executed. The developer declares a variable that needsthe folder location that the code executes from.

Which global variable can be used in the script?



Answer : B


Page:    1 / 14   
Total 224 questions