Skip to content

Commit

Permalink
don't create xref index on single-file projects
Browse files Browse the repository at this point in the history
  • Loading branch information
cscheid committed Mar 15, 2024
1 parent d2a1ee2 commit a492383
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/command/render/crossref.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ export function crossrefFilterParams(
// validation
if (option === kNumberOffset) {
// coerce scalar number-offset to array
if (typeof (value) === "number") {
if (typeof value === "number") {
value = [value];
}
// validate we have an array
Expand All @@ -66,7 +66,7 @@ export function crossrefFilterParams(
params[kNumberDepth] = metadata?.[kNumberDepth];

// always create crossref index for projects
if (options.project) {
if (!options.project?.isSingleFile) {
// if its a book then only write for multi-file (as otherwise all of the
// crossref entries will end in a single index file)
if (
Expand Down

0 comments on commit a492383

Please sign in to comment.