fix relative path resolution in router and link crawling
This commit is contained in:
		
							parent
							
								
									232652149a
								
							
						
					
					
						commit
						2f6747b166
					
				
					 44 changed files with 160 additions and 106 deletions
				
			
		| 
						 | 
				
			
			@ -1,13 +1,13 @@
 | 
			
		|||
import path from "path"
 | 
			
		||||
import fs from "fs"
 | 
			
		||||
import { PerfTimer } from "../perf"
 | 
			
		||||
import { PerfTimer } from "../util/perf"
 | 
			
		||||
import { getStaticResourcesFromPlugins } from "../plugins"
 | 
			
		||||
import { EmitCallback } from "../plugins/types"
 | 
			
		||||
import { ProcessedContent } from "../plugins/vfile"
 | 
			
		||||
import { FilePath, joinSegments } from "../path"
 | 
			
		||||
import { QuartzLogger } from "../log"
 | 
			
		||||
import { trace } from "../trace"
 | 
			
		||||
import { BuildCtx } from "../ctx"
 | 
			
		||||
import { FilePath, joinSegments } from "../util/path"
 | 
			
		||||
import { QuartzLogger } from "../util/log"
 | 
			
		||||
import { trace } from "../util/trace"
 | 
			
		||||
import { BuildCtx } from "../util/ctx"
 | 
			
		||||
 | 
			
		||||
export async function emitContent(ctx: BuildCtx, content: ProcessedContent[]) {
 | 
			
		||||
  const { argv, cfg } = ctx
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -1,5 +1,5 @@
 | 
			
		|||
import { BuildCtx } from "../ctx"
 | 
			
		||||
import { PerfTimer } from "../perf"
 | 
			
		||||
import { BuildCtx } from "../util/ctx"
 | 
			
		||||
import { PerfTimer } from "../util/perf"
 | 
			
		||||
import { ProcessedContent } from "../plugins/vfile"
 | 
			
		||||
 | 
			
		||||
export function filterContent(ctx: BuildCtx, content: ProcessedContent[]): ProcessedContent[] {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -5,14 +5,14 @@ import { Processor, unified } from "unified"
 | 
			
		|||
import { Root as MDRoot } from "remark-parse/lib"
 | 
			
		||||
import { Root as HTMLRoot } from "hast"
 | 
			
		||||
import { ProcessedContent } from "../plugins/vfile"
 | 
			
		||||
import { PerfTimer } from "../perf"
 | 
			
		||||
import { PerfTimer } from "../util/perf"
 | 
			
		||||
import { read } from "to-vfile"
 | 
			
		||||
import { FilePath, QUARTZ, slugifyFilePath } from "../path"
 | 
			
		||||
import { FilePath, QUARTZ, slugifyFilePath } from "../util/path"
 | 
			
		||||
import path from "path"
 | 
			
		||||
import workerpool, { Promise as WorkerPromise } from "workerpool"
 | 
			
		||||
import { QuartzLogger } from "../log"
 | 
			
		||||
import { trace } from "../trace"
 | 
			
		||||
import { BuildCtx } from "../ctx"
 | 
			
		||||
import { QuartzLogger } from "../util/log"
 | 
			
		||||
import { trace } from "../util/trace"
 | 
			
		||||
import { BuildCtx } from "../util/ctx"
 | 
			
		||||
 | 
			
		||||
export type QuartzProcessor = Processor<MDRoot, HTMLRoot, void>
 | 
			
		||||
export function createProcessor(ctx: BuildCtx): QuartzProcessor {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue