mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-15 01:57:28 +02:00
Add customize highlight.theme custom path support (#517)
* add themeUrl option to support custom theme file path * Update api-site-config.md
This commit is contained in:
parent
40a9047620
commit
aa32ff4a55
3 changed files with 12 additions and 15 deletions
|
@ -33,12 +33,6 @@ class Site extends React.Component {
|
|||
(this.props.url || 'index.html');
|
||||
let docsVersion = this.props.version || 'current';
|
||||
|
||||
const highlightDefaultVersion = '9.12.0';
|
||||
const highlightConfig = this.props.config.highlight || {
|
||||
version: highlightDefaultVersion,
|
||||
theme: 'default',
|
||||
};
|
||||
const highlightVersion = highlightConfig.version || highlightDefaultVersion;
|
||||
if (fs.existsSync(CWD + '/versions.json')) {
|
||||
const latestVersion = require(CWD + '/versions.json')[0];
|
||||
if (docsVersion === latestVersion) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue