mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-21 04:57:05 +02:00
chore(v2): Fix linter warnings (#4442)
* chore(v2): Fix linter warnings 223 warnings to 145 warnings * Remove explicit type annotations * Do not prefetch when targetLink == null
This commit is contained in:
parent
f041a37622
commit
5e73c72f26
39 changed files with 146 additions and 71 deletions
|
@ -10,6 +10,8 @@ import {merge} from 'lodash';
|
|||
const {ThemeConfigSchema, DEFAULT_CONFIG} = require('../validateThemeConfig');
|
||||
|
||||
const {normalizeThemeConfig} = require('@docusaurus/utils-validation');
|
||||
const theme = require('prism-react-renderer/themes/github');
|
||||
const darkTheme = require('prism-react-renderer/themes/dracula');
|
||||
|
||||
function testValidateThemeConfig(partialThemeConfig) {
|
||||
return normalizeThemeConfig(ThemeConfigSchema, {
|
||||
|
@ -31,8 +33,8 @@ describe('themeConfig', () => {
|
|||
test('should accept valid theme config', () => {
|
||||
const userConfig = {
|
||||
prism: {
|
||||
theme: require('prism-react-renderer/themes/github'),
|
||||
darkTheme: require('prism-react-renderer/themes/dracula'),
|
||||
theme,
|
||||
darkTheme,
|
||||
defaultLanguage: 'javascript',
|
||||
additionalLanguages: ['kotlin', 'java'],
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue