QuestionQ64

VerifiedBasic Lightning Web Component Development

Which two code blocks are required to implement a custom getter in a Lightning web component?

Choose two
Explanation

Lightning Web Components use standard JavaScript accessor syntax: get returns a property value and set receives and stores an assigned value. A public getter/setter pair can have @api applied to either accessor, but the decorator is separate from the get or set keyword; @apiget and @apiset are not valid syntax.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!