@docusaurus/plugin-content-blog 4.0.0-canary-6835 → 4.0.0-canary-6840

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/blogUtils.js CHANGED
@@ -22,6 +22,7 @@ const path_1 = tslib_1.__importDefault(require("path"));
22
22
  const lodash_1 = tslib_1.__importDefault(require("lodash"));
23
23
  const logger_1 = tslib_1.__importDefault(require("@docusaurus/logger"));
24
24
  const utils_1 = require("@docusaurus/utils");
25
+ const glob_1 = require("@docusaurus/glob");
25
26
  const frontMatter_1 = require("./frontMatter");
26
27
  const authors_1 = require("./authors");
27
28
  const authorsProblems_1 = require("./authorsProblems");
@@ -267,7 +268,7 @@ async function generateBlogPosts(contentPaths, context, options, tagsFile, autho
267
268
  if (!(await fs_extra_1.default.pathExists(contentPaths.contentPath))) {
268
269
  return [];
269
270
  }
270
- const blogSourceFiles = await (0, utils_1.Globby)(include, {
271
+ const blogSourceFiles = await (0, glob_1.glob)(include, {
271
272
  cwd: contentPaths.contentPath,
272
273
  ignore: exclude,
273
274
  });
package/lib/index.js CHANGED
@@ -13,6 +13,7 @@ const path_1 = tslib_1.__importDefault(require("path"));
13
13
  const logger_1 = tslib_1.__importDefault(require("@docusaurus/logger"));
14
14
  const combine_promises_1 = tslib_1.__importDefault(require("combine-promises"));
15
15
  const utils_1 = require("@docusaurus/utils");
16
+ const glob_1 = require("@docusaurus/glob");
16
17
  const utils_validation_1 = require("@docusaurus/utils-validation");
17
18
  const mdx_loader_1 = require("@docusaurus/mdx-loader");
18
19
  const blogUtils_1 = require("./blogUtils");
@@ -70,7 +71,7 @@ async function pluginContentBlog(context, options) {
70
71
  beforeDefaultRehypePlugins,
71
72
  staticDirs: siteConfig.staticDirectories.map((dir) => path_1.default.resolve(siteDir, dir)),
72
73
  siteDir,
73
- isMDXPartial: (0, utils_1.createAbsoluteFilePathMatcher)(options.exclude, contentDirs),
74
+ isMDXPartial: (0, glob_1.createAbsoluteFilePathMatcher)(options.exclude, contentDirs),
74
75
  metadataPath: (mdxPath) => {
75
76
  // Note that metadataPath must be the same/in-sync as
76
77
  // the path from createData for each MDX.
package/lib/options.js CHANGED
@@ -12,6 +12,7 @@ const tslib_1 = require("tslib");
12
12
  const path_1 = tslib_1.__importDefault(require("path"));
13
13
  const utils_validation_1 = require("@docusaurus/utils-validation");
14
14
  const utils_1 = require("@docusaurus/utils");
15
+ const glob_1 = require("@docusaurus/glob");
15
16
  exports.DEFAULT_OPTIONS = {
16
17
  id: utils_1.DEFAULT_PLUGIN_ID,
17
18
  feedOptions: {
@@ -44,7 +45,7 @@ exports.DEFAULT_OPTIONS = {
44
45
  blogSidebarTitle: 'Recent posts',
45
46
  postsPerPage: 10,
46
47
  include: ['**/*.{md,mdx}'],
47
- exclude: utils_1.GlobExcludeDefault,
48
+ exclude: glob_1.GlobExcludeDefault,
48
49
  routeBasePath: 'blog',
49
50
  tagsBasePath: 'tags',
50
51
  archiveBasePath: 'archive',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@docusaurus/plugin-content-blog",
3
- "version": "4.0.0-canary-6835",
3
+ "version": "4.0.0-canary-6840",
4
4
  "description": "Blog plugin for Docusaurus.",
5
5
  "main": "lib/index.js",
6
6
  "types": "src/plugin-content-blog.d.ts",
@@ -31,15 +31,16 @@
31
31
  },
32
32
  "license": "MIT",
33
33
  "dependencies": {
34
- "@docusaurus/core": "4.0.0-canary-6835",
35
- "@docusaurus/logger": "4.0.0-canary-6835",
36
- "@docusaurus/mdx-loader": "4.0.0-canary-6835",
37
- "@docusaurus/module-type-aliases": "4.0.0-canary-6835",
38
- "@docusaurus/theme-common": "4.0.0-canary-6835",
39
- "@docusaurus/types": "4.0.0-canary-6835",
40
- "@docusaurus/utils": "4.0.0-canary-6835",
41
- "@docusaurus/utils-common": "4.0.0-canary-6835",
42
- "@docusaurus/utils-validation": "4.0.0-canary-6835",
34
+ "@docusaurus/core": "4.0.0-canary-6840",
35
+ "@docusaurus/glob": "4.0.0-canary-6840",
36
+ "@docusaurus/logger": "4.0.0-canary-6840",
37
+ "@docusaurus/mdx-loader": "4.0.0-canary-6840",
38
+ "@docusaurus/module-type-aliases": "4.0.0-canary-6840",
39
+ "@docusaurus/theme-common": "4.0.0-canary-6840",
40
+ "@docusaurus/types": "4.0.0-canary-6840",
41
+ "@docusaurus/utils": "4.0.0-canary-6840",
42
+ "@docusaurus/utils-common": "4.0.0-canary-6840",
43
+ "@docusaurus/utils-validation": "4.0.0-canary-6840",
43
44
  "cheerio": "^1.2.0",
44
45
  "combine-promises": "^1.2.0",
45
46
  "feed": "^5.2.1",
@@ -63,5 +64,5 @@
63
64
  "@total-typescript/shoehorn": "^0.1.2",
64
65
  "tree-node-cli": "^3.0.0"
65
66
  },
66
- "gitHead": "545ee70227b7e3446e96056b3c5e7796711e42b4"
67
+ "gitHead": "b767143bc76b7747a9d1cc747dece7b06195a5c0"
67
68
  }
package/src/blogUtils.ts CHANGED
@@ -16,7 +16,6 @@ import {
16
16
  getEditUrl,
17
17
  getFolderContainingFile,
18
18
  posixPath,
19
- Globby,
20
19
  groupTaggedItems,
21
20
  getTagVisibility,
22
21
  getContentPathList,
@@ -26,6 +25,7 @@ import {
26
25
  normalizeTags,
27
26
  aliasedSitePathToRelativePath,
28
27
  } from '@docusaurus/utils';
28
+ import {glob} from '@docusaurus/glob';
29
29
 
30
30
  import {validateBlogPostFrontMatter} from './frontMatter';
31
31
  import {getBlogPostAuthors} from './authors';
@@ -424,7 +424,7 @@ export async function generateBlogPosts(
424
424
  return [];
425
425
  }
426
426
 
427
- const blogSourceFiles = await Globby(include, {
427
+ const blogSourceFiles = await glob(include, {
428
428
  cwd: contentPaths.contentPath,
429
429
  ignore: exclude,
430
430
  });
package/src/index.ts CHANGED
@@ -16,12 +16,12 @@ import {
16
16
  getPluginI18nPath,
17
17
  posixPath,
18
18
  addTrailingPathSeparator,
19
- createAbsoluteFilePathMatcher,
20
19
  getContentPathList,
21
20
  getDataFilePath,
22
21
  resolveMarkdownLinkPathname,
23
22
  getLocaleConfig,
24
23
  } from '@docusaurus/utils';
24
+ import {createAbsoluteFilePathMatcher} from '@docusaurus/glob';
25
25
  import {
26
26
  getTagsFilePathsToWatch,
27
27
  getTagsFile,
package/src/options.ts CHANGED
@@ -15,7 +15,8 @@ import {
15
15
  RouteBasePathSchema,
16
16
  URISchema,
17
17
  } from '@docusaurus/utils-validation';
18
- import {DEFAULT_PLUGIN_ID, GlobExcludeDefault} from '@docusaurus/utils';
18
+ import {DEFAULT_PLUGIN_ID} from '@docusaurus/utils';
19
+ import {GlobExcludeDefault} from '@docusaurus/glob';
19
20
  import type {
20
21
  PluginOptions,
21
22
  Options,