# useOrganization() | Vue

The `useOrganization()` composable retrieves attributes of the currently Active Organization.

## Returns

| Name         | Type                         | Description                                                                                                                                                                                                                                                                                 |
| ------------ | ---------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| isLoaded     | Ref<boolean>                | A boolean that indicates whether Clerk has completed initialization. Initially false, becomes true once Clerk loads.                                                                                                                                                                        |
| organization | Ref<Organization>           | The currently Active OrganizationA user can be a member of multiple Organizations, but only one can be active at a time. The Active Organization determines which Organization-specific data the user can access and which Role and related Permissions they have within the Organization.. |
| membership   | Ref<OrganizationMembership> | The current Organization membership.                                                                                                                                                                                                                                                        |

## How to use the `useOrganization()` composable

### Retrieve the current Active Organization

The following example demonstrates how to use the [useOrganization()](https://clerk.com/docs/vue/reference/composables/use-organization.md) composable to access the active [Organization](https://clerk.com/docs/vue/reference/objects/organization.md) object.

filename: OrganizationStatus.vue
```vue
<script setup>
import { OrganizationSwitcher, useOrganization } from '@clerk/vue'

const { organization, isLoaded } = useOrganization()
</script>

<template>
  <div v-if="!organization">
    <OrganizationSwitcher />
  </div>
  <div v-if="isLoaded">
    <p>This current Organization is {{ organization?.name }}</p>
  </div>

  <div v-else>
    <p>Loading...</p>
  </div>
</template>
```

### Paginate Organization memberships

The following example demonstrates how to use `useOrganization()` to access the Organization's memberships. Pagination is implemented by fetching pages of memberships when the "Previous page" or "Next page" buttons are clicked.

filename: MembershipList.vue
```vue
<script setup>
import { ref, watchEffect } from 'vue'
import { OrganizationSwitcher, useOrganization } from '@clerk/vue'

const memberships = ref([])
const currentPage = ref(1)
const { organization, isLoaded } = useOrganization()

const pageSize = 5

async function fetchMemberships() {
  if (!organization.value) {
    return
  }

  // Use the `getMemberships()` method on the `organization` object to fetch the organization's memberships.
  const { data } = await organization.value.getMemberships({
    initialPage: currentPage.value,
    pageSize: pageSize,
  })
  memberships.value = data
}

watchEffect(() => {
  if (!organization.value) {
    return
  }

  fetchMemberships()
})

const fetchPrevious = () => currentPage.value--
const fetchNext = () => currentPage.value++
</script>

<template>
  <div v-if="!organization">
    <OrganizationSwitcher />
  </div>

  <div v-else-if="isLoaded">
    <h2>Organization members</h2>

    <ul>
      <li v-for="membership in memberships" :key="membership.id">
        {{ membership.publicUserData.firstName }} {{ membership.publicUserData.lastName }} &lt;{{
          membership.publicUserData.identifier
        }}&gt; :: {{ membership.role }}
      </li>
    </ul>

    <div>
      <button :disabled="currentPage === 1" @click="fetchPrevious">Previous</button>
      <button :disabled="memberships.length < pageSize" @click="fetchNext">Next</button>
    </div>
  </div>

  <div v-else>
    <p>Loading...</p>
  </div>
</template>
```

---

## Sitemap

[Overview of all docs pages](https://clerk.com/docs/llms.txt)
