mirror of
https://github.com/facebook/docusaurus.git
synced 2025-07-13 06:48:08 +02:00
refactor: move exported type definitions to declaration file (#6300)
* refactor: move exported type definitions to declaration file * fix * fix
This commit is contained in:
parent
9c0e659a44
commit
cf265c051e
53 changed files with 482 additions and 452 deletions
|
@ -10,12 +10,10 @@ import path from 'path';
|
|||
import readingTime from 'reading-time';
|
||||
import {keyBy, mapValues} from 'lodash';
|
||||
import type {
|
||||
PluginOptions,
|
||||
BlogPost,
|
||||
BlogContentPaths,
|
||||
BlogMarkdownLoaderOptions,
|
||||
BlogTags,
|
||||
ReadingTimeFunction,
|
||||
} from './types';
|
||||
import {
|
||||
parseMarkdownFile,
|
||||
|
@ -34,6 +32,10 @@ import type {LoadContext} from '@docusaurus/types';
|
|||
import {validateBlogPostFrontMatter} from './blogFrontMatter';
|
||||
import {type AuthorsMap, getAuthorsMap, getBlogPostAuthors} from './authors';
|
||||
import logger from '@docusaurus/logger';
|
||||
import type {
|
||||
PluginOptions,
|
||||
ReadingTimeFunction,
|
||||
} from '@docusaurus/plugin-content-blog';
|
||||
|
||||
export function truncate(fileString: string, truncateMarker: RegExp): string {
|
||||
return fileString.split(truncateMarker, 1).shift()!;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue