// @ts-check // Note: type annotations allow type checking and IDEs autocompletion const lightCodeTheme = require('prism-react-renderer/themes/github'); const darkCodeTheme = require('prism-react-renderer/themes/dracula'); /** @type {import('@docusaurus/types').Config} */ const config = { title: 'Ransack documentation', tagline: 'Object-based searching', url: 'https://activerecord-hackery.github.io', baseUrl: '/ransack/', //onBrokenLinks: 'throw', onBrokenMarkdownLinks: 'warn', favicon: 'img/favicon.ico', organizationName: 'activerecord-hackery', projectName: 'ransack', trailingSlash: false, presets: [ [ 'classic', /** @type {import('@docusaurus/preset-classic').Options} */ ({ docs: { routeBasePath: '/', sidebarPath: require.resolve('./sidebars.js'), editUrl: 'https://github.com/activerecord-hackery/ransack/docs/docs/', }, blog: { showReadingTime: true, editUrl: 'https://github.com/activerecord-hackery/ransack/docs/blog/', }, theme: { customCss: require.resolve('./src/css/custom.css'), }, }), ], ], themeConfig: /** @type {import('@docusaurus/preset-classic').ThemeConfig} */ ({ navbar: { logo: { alt: 'Ransack Logo', src: './logo/ransack-h.png', }, items: [ { type: 'doc', docId: 'intro', position: 'left', label: 'Documentation', }, {to: '/blog', label: 'Blog', position: 'left'}, { href: 'https://github.com/activerecord-hackery/ransack', label: 'GitHub', position: 'right', }, ], }, footer: { style: 'dark', links: [ { title: 'Docs', items: [ { label: 'Documentation', to: '/', }, ], }, { title: 'Community', items: [ { label: 'Stack Overflow', href: 'https://stackoverflow.com/questions/tagged/ransack', }, ], }, { title: 'More', items: [ { label: 'Blog', to: '/blog', }, { label: 'GitHub', href: 'https://github.com/activerecord-hackery/ransack', }, ], }, ], }, prism: { theme: lightCodeTheme, darkTheme: darkCodeTheme, }, }), }; module.exports = config;