New Year Sale Special Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: xmas50

Salesforce JavaScript-Developer-I - Salesforce Certified JavaScript Developer (JS-Dev-101)

Page: 3 / 7
Total 219 questions

Refer to the code below:

01 const server = require(‘server’);

02 /* Insert code here */

A developer imports a library that creates a web server. Theimported library uses events and

callbacks to start the servers

Which code should be inserted at the line 03 to set up an event and start the web server ?

A.

Server.start ();

B.

server.on(‘ connect ’ , ( port) => {console.log(‘Listening on ’ , port) ;})

C.

server()

D.

serve(( port) => (

E.

console.log( ‘Listening on ’, port) ;

Which option istrue about the strict mode in imported modules?

A.

Add the statement use non-strict, before any other statements in the module to enablenot-strict mode.

B.

You can only reference notStrict() functions from the imported module.

C.

Imported modules are in strict mode whether you declare them as such or not.

D.

Add the statement use strict =false; before any other statements in the module to enablenot- strict mode.

Refer to the code below:

const event = new CustomEvent(

//Missing Code

);

obj.dispatchEvent(event);

A developer needs to dispatch a custom event called update to send information about

recordId.

Which two options could a developer insert at the placeholder in line 02 to achieve this?

Choose 2 answers

A.

‘Update’ , (recordId : ‘123abc’(

B.

‘Update’ , ‘123abc’

C.

{ type : ‘update’, recordId : ‘123abc’ }

D.

‘Update’ , {Details : {recordId : ‘123abc’}}

Which three browser specific APIs are available for developers to persist data between page loads ?

Choose 3 answers

A.

IIFEs

B.

indexedDB

C.

Global variables

D.

Cookies

E.

localStorage.

Whichthree actions can be using the JavaScript browser console?

Choose 3 answers:

A.

View and change DOM the page.

B.

Display a report showing the performance of a page.

C.

Run code that is not related to page.

D.

view , change, and debug the JavaScript code ofthe page.

E.

View and change security cookies.

Which statement accurately describes the behaviour of the async/ await keyworks ?

A.

The associated class contains some asynchronous functions.

B.

The associated function will always return a promise

C.

Theassociated function can only be called via asynchronous methods

D.

The associated sometimes returns a promise.

A developer wants to create an object from a function in the browser using the code

below:

Function Monster() { this.name = ‘hello’ };

Const z = Monster();

What happens due to lackof the new keyword on line 02?

A.

The z variable is assigned the correct object.

B.

The z variable is assigned the correct object but this.name remains undefined.

C.

Window.name is assigned to ‘hello’ and the variable z remains undefined.

D.

Window.m is assigned the correct object.

Which option is a core Node,js module?

A.

Path

B.

Ios

C.

Memory

D.

locate

After user acceptance testing, the developer is asked to change the webpage background based on user's location. This change was implemented and deployed for testing.

The tester reports that the background is not changing, however it works as required when viewing on the developer's computer.

Which two actions will help determine accurate results?

Choose 2 answers

A.

The developer should inspect their browser refresh settings.

B.

The tester should disable their browser cache.

C.

The developer should rework the code.

D.

The tester should dear their browser cache.

bar, awesome is a popular JavaScript module. the versions publish to npm are:

Teams at Universal Containers use this module in a number of projects. A particular project has thepackage, json definition below.

A developer runs this command: npm install.

Which version of bar .awesome is installed?

A.

1.3.1

B.

1.3.5

C.

The command fails, because version 130 is not found

D.

1.4.0