<template>
  <div>{{ documents }}</div>
</template>

<script setup>
import { document } from '@/plugins/api';
import router from '@/router';
import {ref} from 'vue'

const libraryId = router.currentRoute.value.params.LibraryId
const page = ref(1)
const documents = ref([])
const loading = ref(false)

function load() {
  loading.value = true

  document.libraryLibraryIdDocumentsGet(libraryId, page.value).then((r) => {
    documents.value = r.data
  }).finally(() => {
    loading.value = false
  })
}

load()
console.log(libraryId)


</script>
