mirror of
https://github.com/facebook/docusaurus.git
synced 2025-08-06 10:20:09 +02:00
feat(core): allow plugin lifecycles to return relative paths (#6921)
* feat(core): resolve plugin lifecycles returning relative paths * fix typo * fix tests * revert * rename path -> entryPath
This commit is contained in:
parent
8d1c1954c1
commit
68aaf9201f
26 changed files with 100 additions and 68 deletions
|
@ -15,8 +15,6 @@ import type {PluginOptions} from '@docusaurus/plugin-ideal-image';
|
|||
import {Joi} from '@docusaurus/utils-validation';
|
||||
import {readDefaultCodeTranslationMessages} from '@docusaurus/theme-translations';
|
||||
|
||||
import path from 'path';
|
||||
|
||||
export default function pluginIdealImage(
|
||||
context: LoadContext,
|
||||
options: PluginOptions,
|
||||
|
@ -29,11 +27,11 @@ export default function pluginIdealImage(
|
|||
name: 'docusaurus-plugin-ideal-image',
|
||||
|
||||
getThemePath() {
|
||||
return path.resolve(__dirname, '../lib/theme');
|
||||
return '../lib/theme';
|
||||
},
|
||||
|
||||
getTypeScriptThemePath() {
|
||||
return path.resolve(__dirname, '../src/theme');
|
||||
return '../src/theme';
|
||||
},
|
||||
|
||||
getDefaultCodeTranslationMessages() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue