methods/get-customer-name.js

  1. import {
  2. nickname as getNickname
  3. } from '@ecomplus/utils'
  4. /**
  5. * @method
  6. * @name EcomPassport#getCustomerName
  7. * @description Get nickname or given name from current customer account data.
  8. *
  9. * @returns {string}
  10. *
  11. * @example
  12. ecomPassport.getCustomerName()
  13. */
  14. export default self => getNickname(self.getCustomer())