chore: expose MarkerIdAssigner from plugin
This commit is contained in:
parent
6c114d3021
commit
88c6d820f8
|
@ -1455,7 +1455,7 @@ export async function generateSearchIndex(options: Options, assigner: MarkerIdAs
|
||||||
}
|
}
|
||||||
|
|
||||||
// Rollup プラグインとして export
|
// Rollup プラグインとして export
|
||||||
export default function pluginCreateSearchIndex(options: Options): Plugin {
|
export default function pluginCreateSearchIndex(options: Options): Plugin<MarkerIdAssigner> {
|
||||||
const assigner = new MarkerIdAssigner();
|
const assigner = new MarkerIdAssigner();
|
||||||
const isDevServer = process.env.NODE_ENV === 'development'; // 開発サーバーかどうか
|
const isDevServer = process.env.NODE_ENV === 'development'; // 開発サーバーかどうか
|
||||||
|
|
||||||
|
@ -1464,6 +1464,7 @@ export default function pluginCreateSearchIndex(options: Options): Plugin {
|
||||||
return {
|
return {
|
||||||
name: 'createSearchIndex',
|
name: 'createSearchIndex',
|
||||||
enforce: 'pre',
|
enforce: 'pre',
|
||||||
|
api: assigner,
|
||||||
|
|
||||||
async buildStart() {
|
async buildStart() {
|
||||||
if (!isDevServer) {
|
if (!isDevServer) {
|
||||||
|
|
Loading…
Reference in New Issue