[Jul-2021] B2C-Commerce-Developer Dumps Full Questions - Salesforce Developers Exam Study Guide [Q14-Q31]

Share

[Jul-2021] B2C-Commerce-Developer Dumps Full Questions - Salesforce Developers Exam Study Guide

Exam Questions and Answers for  B2C-Commerce-Developer Study Guide

NEW QUESTION 14
The following sample code is NOT providing the desired results. The Digital Developer needs to add an entry to the logs to debug the problem.

Which statement correctly adds a log entry?

  • A. Logger.getErrorI_og().log('Unable to find Apple Pay payment instrument for order.'+paymentlnstruments);
  • B. Logger.exception('Unable to find Apple Pay payment instrument for order.'+paymentlnstruments);
  • C. Logger.fault('Unable to find Apple Pay payment instrument for order.'+paymentlnstruments);
  • D. Logger.error('Unable to find Apple Pay payment instrument for order.'+paymentlnstruments);

Answer: D

 

NEW QUESTION 15
Which three techniques improve client-side performance in production while following documented best practices? Choose 3 answers

  • A. Use inline Javascript.
  • B. Combine several images into a single image.
  • C. Use one style sheet for each ISML decorator template.
  • D. Compress CSS.
  • E. Place CSS outside of templates.

Answer: A,B,D

 

NEW QUESTION 16
Assume the code below is executing:

Business Manager has the configuration:
* Active Log category is "root" with log level of "info."
Given this information, what is the beginning of the filename in which the log will be written?

  • A. custom-xyz
  • B. custominfo-blade
  • C. xyz
  • D. custom-export

Answer: A

 

NEW QUESTION 17
A retailer notices that the Account Addresses page is showing the wrong shopper's address.
Which tool should the developer start with to identify the issue?

  • A. Reports and Dashboards module
  • B. Code Profiler
  • C. Pipeline Profiler
  • D. Storefront Toolkit

Answer: B

 

NEW QUESTION 18
The developer created a new Storefront category in storefront-catalog-m-en, but when viewing the Storefront site, the category is not visible.
What are two possible reasons? (Choose two.)

  • A. The category is not sorted
  • B. The category is offline
  • C. The Storefront catalog is offline
  • D. The category does not contain available products

Answer: B,D

Explanation:
Explanation/Reference: https://documentation.b2c.commercecloud.salesforce.com/DOC3/index.jsp?topic=%
2Fcom.demandware.dochelp%2FLegacyDevDoc%2FCategoriesdonotshowinstorefront.html

 

NEW QUESTION 19
Once the Cache Information tool of the storefront toolkit is enabled, how can a Digital Developer view caching information for a particular component of the page?

  • A. Open the Request Logs to view the caching information.
  • B. Start a pipeline debugging session and view the caching information provided.
  • C. Hover over the caching icons now present on the storefront.
  • D. Right-click on the component in UX Studio and view the caching properties of the file.

Answer: C

 

NEW QUESTION 20
The Home-Show route uses this middleware chain:
server.get('Show', consentTracking.consent, cache.applyDefaultCache, function (req, res, next) {
// based code here
});
The developer added Home.jsin another cartridge, which is before the original cartridge in the cartridge path, to extend that route but it does not have the middleware chain:
server.append('Show', function (req, res, next) {
// custom code here
});
Assuming the code is correct on both functions, what is the expected result?

  • A. The base code executes, but the custom code is ignored because the signature lines do not match
  • B. The custom code executes and then the base code executes
  • C. The base code executes and then the custom code executes
  • D. A RunTime error is thrown, "Error: Params do not match route"

Answer: D

 

NEW QUESTION 21
A developer wants to add a link to the My Account Page.
What is the correct code to accomplish this?

  • A. <a
    href="${URLUtils.get('Account-Show')}>${Resource.msg('myaccount','account',request.locale())}</a>
  • B. <a href="${URLUtils
    ('Account-Show')}>${ResourceMgr.getPropierties('myaccount','account',null)}</a>
  • C. <a href="${url.get('Account-Show')}>${Resource.message('myaccount')}</a>
  • D. <a href="${URLUtils.url('Account-Show')}>${Resource.msg('myaccount','account',null)}</a>

Answer: D

 

NEW QUESTION 22
A client has two B2C Commerce sites in the same instance: one for the U.S market, the other for the European market. The products they make are sold with different safety certificates based-on the world location.
For example, they sell a smartphone with certificate A in the U.S and certificate B in Europe, a hairdryer with certificate C in the U.S and certificate D in Europe, and more.
How should a developer allow the merchant to display the appropriate certification logo in the produce to details page, depending on the customer's location?

  • A. Add a Site-specific custom attribute to the Product system object type.
  • B. Ad and Image custom preference to the Sitepreference system object type
  • C. Add a Localizable custom preference to the SitePreference system object type.
  • D. Add a Localizable custom attribute to the Certificate system object type.

Answer: A

Explanation:

 

NEW QUESTION 23
To ensure SFRA best practices and protect against request forgery, the developer introduced CSRF token generation in the customer address form:
<form ... action = "submit">
<input name ="${dw.web.CSRFProtection.getTokenName()}"
value = "${dw.web.CSRFProtection.generateToken()">
...
<the rest of the Form fields>
...
</form>
To implement CSRF protection when the form is submitted, the developer needs to introduce the CSRF validation using one or both of these methods as applicable:
* validateRequest
* validateAjaxRequest
Where in the code does the developer need to add this CSRF validation check?

  • A. In the controller function that displays the form
  • B. In the middleware chain of the controller post route
  • C. In the model function that persists the form data
  • D. In the controller function that handles the submitted form

Answer: B

 

NEW QUESTION 24
A Digital Developer has identified that the code segment below is causing performance problems.

What should the Developer do to improve the code?

  • A. Breaks the process into separate loops.
  • B. Avoid post-processing and use the isOnSaleFlag attribute as a search refinement.
  • C. Use a system attribute instead of the isOnSaleFlag custom attribute.
  • D. Avoid using an Iterator and use a Collection instead.

Answer: A

 

NEW QUESTION 25
Which two methods are efficient and scalable? (Choose two.)

  • A. ProductSearchModel.getProductSearchHits()
  • B. ProductSearchHit.getRepresentedProducts()
  • C. Category.getProducts()
  • D. ProductMgr.queryAllSiteProducts()

Answer: A,C

 

NEW QUESTION 26
Why should a Digital Developer use ProductSearchModel.getProducts() instead of Category.getOnlineProducts() to access products?

  • A. It reduces accesses to the application server.
  • B. It is more readable code.
  • C. It has fewer lines of code.
  • D. It uses the search index.

Answer: A

 

NEW QUESTION 27
Which two items are appropriate content of custom logs implemented at checkout?
Choose 2 answers:

  • A. Order failure information
  • B. Transaction's credit card information
  • C. Payment gateway service response code
  • D. Customer's password at post-checkout sign up

Answer: A,C

 

NEW QUESTION 28
A developer has the following files in template/resources:
account.proierties
weight.unit=kilos
account_en.propierties
weight.unit=stones
account_en_US.propierties
weight.unit= pounds
Using the default locale configuration, what is the current outcome of the page that renders the account.isml template snippet below when visiting the Sofrefront with the English for Canada(en_CA) locale= Your parcel weighs 10 ${Resource.msg('weight.unit','account')}

  • A. Your parcel weighs 10 pounds.
  • B. Your parcel weighs 10 kilos
  • C. Your parcel weighs 10 stones.
  • D. Your parcel weighs 10 undefined.

Answer: C

 

NEW QUESTION 29
A Digital Developer is asked to optimize controller performance by lazy loading scripts as needed instead of loading all scripts at the start of the code execution.
Which statement should the Developer use to lazy load scripts?

  • A. importPackage () method
  • B. local include
  • C. $.ajax () jQuery method
  • D. require () method

Answer: D

 

NEW QUESTION 30
A Digital Developer is inspecting the weekly service status report for a critical internally-hosted web service used in the application and notices that there are too many instances of unavailability.
Which two solutions are possible options to reduce the unavailability of the service? (Choose two.)

  • A. Change the code that makes the request to set the throwOnError attribute, of the service, to be true.
  • B. Increase the web service time out.
  • C. Modify the code that makes the request to the external service to be wrapped in a try / catch block.
  • D. Update the external service to have a faster response time.

Answer: C,D

 

NEW QUESTION 31
......

Salesforce Certified B2C Commerce Developer Free Update With 100% Exam Passing Guarantee: https://www.troytecdumps.com/B2C-Commerce-Developer-troytec-exam-dumps.html

Real Exam Questions & Answers - Salesforce B2C-Commerce-Developer Dump is Ready: https://drive.google.com/open?id=1y0WqzVwQKa5zKIksWEzrKJZQfQ12bw0O