import React from 'react'
import DefaultLayout from '@/layouts/DefaultLayout/DefaultLayout'
import { getStaticEntryPaths, getStaticEntryProps } from '@/lib/content'
import Article from '@/components/Article/Article'

export const getStaticPaths = () => getStaticEntryPaths('./content/books')
export const getStaticProps = (ctx) => getStaticEntryProps('./content/books', ctx)

export default function LibrarySingle ({ attributes, html }) {
  return (
    <DefaultLayout>
      <Article attributes={attributes} html={html} />
    </DefaultLayout>
  )
}
