Skip to content

Commit

Permalink
ci: apply automated fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
autofix-ci[bot] authored Dec 10, 2024
1 parent 98c09a5 commit 322299c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
8 changes: 6 additions & 2 deletions packages/router-cli/src/watch.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
import chokidar from 'chokidar'
import { generator, getConfig, resolveConfigPath } from '@tanstack/router-generator'
import {
generator,
getConfig,
resolveConfigPath,
} from '@tanstack/router-generator'

export function watch(root: string) {
const configPath = resolveConfigPath({
configDirectory: root,
});
})
const configWatcher = chokidar.watch(configPath)

let watcher = new chokidar.FSWatcher({})
Expand Down
6 changes: 3 additions & 3 deletions packages/router-generator/src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,11 @@ export const configSchema = z.object({
export type Config = z.infer<typeof configSchema>

type ResolveParams = {
configDirectory: string;
configDirectory: string
}

export function resolveConfigPath({ configDirectory }: ResolveParams) {
return path.resolve(configDirectory, 'tsr.config.json');
return path.resolve(configDirectory, 'tsr.config.json')
}

export function getConfig(
Expand All @@ -82,7 +82,7 @@ export function getConfig(
if (configDirectory === undefined) {
configDirectory = process.cwd()
}
const configFilePathJson = resolveConfigPath({ configDirectory });
const configFilePathJson = resolveConfigPath({ configDirectory })
const exists = existsSync(configFilePathJson)

let config: Config
Expand Down

0 comments on commit 322299c

Please sign in to comment.