puppeteer/website/docusaurus.config.js

73 lines
2.1 KiB
JavaScript
Raw Normal View History

/**
* Copyright 2021 Google Inc. All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
const lightCodeTheme = require('prism-react-renderer/themes/github');
const darkCodeTheme = require('prism-react-renderer/themes/dracula');
/** @type {import('@docusaurus/types').DocusaurusConfig} */
module.exports = {
title: 'Puppeteer documentation',
tagline: 'Note: this documentation is WIP. Please use https://pptr.dev.',
url: 'https://puppeteer.github.io/',
baseUrl: '/puppeteer/',
onBrokenLinks: 'throw',
onBrokenMarkdownLinks: 'warn',
favicon: 'img/favicon.ico',
organizationName: 'puppeteer', // Usually your GitHub org/user name.
projectName: 'puppeteer', // Usually your repo name.
themeConfig: {
navbar: {
title: 'Puppeteer',
logo: {
alt: 'My Site Logo',
src: 'img/logo.svg',
},
items: [
{
type: 'doc',
docId: 'intro',
position: 'left',
label: 'Tutorial',
},
{
href: 'https://github.com/puppeteer/puppeteer',
label: 'GitHub',
position: 'right',
},
],
},
footer: {
style: 'dark',
links: [],
},
prism: {
theme: lightCodeTheme,
darkTheme: darkCodeTheme,
},
},
presets: [
[
'@docusaurus/preset-classic',
{
docs: {
sidebarPath: require.resolve('./sidebars.js'),
// Please change this to your repo.
editUrl: 'https://github.com/facebook/puppeteer/edit/main/website/',
},
},
],
],
};