ExamGecko
Question list
Search
Search

List of questions

Search

Question 12 - Certified B2B Commerce Administrator discussion

Report
Export

Which code statement should a developer use to import the ID of the current Lightning 04m 235 Experience Site?

A.
import id from '@salesforce/network/ld'
Answers
A.
import id from '@salesforce/network/ld'
B.
import id from '@salesforce/site/Id'
Answers
B.
import id from '@salesforce/site/Id'
C.
import id from '@salesforce/experience/Id'
Answers
C.
import id from '@salesforce/experience/Id'
D.
import id from '@salesforce/community/Id'
Answers
D.
import id from '@salesforce/community/Id'
Suggested answer: C

Explanation:

The correct answer is C. import id from '@salesforce/experience/Id' because this is the syntax for importing information about the current Experience Builder site from the @salesforce/experience scoped module.The id property returns the ID of the current site1. The other options are incorrect because they use different scoped modules or properties that do not exist or do not return the site ID.Reference:Current Community

asked 23/09/2024
Novy Kingra
43 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first