Function: useAddress()
useAddress(
options):UseAddressReturn
Defined in: composables/react/useAddress.ts:111
useAddress — display and CRUD for company / customer addresses.
Parameters
options
see UseAddressOptions.
Returns
loading/error state plus async CRUD actions — see UseAddressReturn.
Remarks
GraphQL integration: every call goes through services.address (AddressService),
built per-call via createServices(graphqlClient). The user kind decides which
mutation runs — contacts use createCompanyAddress / updateCompanyAddress /
deleteCompanyAddress (companyId from options.companyId or user.company),
customers use createCustomerAddress / updateCustomerAddress /
deleteCustomerAddress (customerId from the user). All mutations require an
authenticated session; methods short-circuit with { success: false } when the
client or user context is missing. setDefaultAddress delegates to updateAddress.