Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@tanstack/router-cli

Package Overview
Dependencies
Maintainers
0
Versions
322
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@tanstack/router-cli - npm Package Compare versions

Comparing version 1.85.10 to 1.86.0

2

dist/esm/generate.d.ts
import { Config } from '@tanstack/router-generator';
export declare function generate(config: Config): Promise<void>;
export declare function generate(config: Config, root: string): Promise<void>;
import { generator } from "@tanstack/router-generator";
async function generate(config) {
async function generate(config, root) {
try {
await generator(config);
await generator(config, root);
process.exit(0);

@@ -6,0 +6,0 @@ } catch (err) {

@@ -9,3 +9,3 @@ import * as yargs from "yargs";

const config = getConfig();
await generate(config);
await generate(config, process.cwd());
}).command(

@@ -15,3 +15,3 @@ "watch",

() => {
watch();
watch(process.cwd());
}

@@ -18,0 +18,0 @@ ).help().argv;

@@ -1,1 +0,1 @@

export declare function watch(): void;
export declare function watch(root: string): void;
import path from "node:path";
import chokidar from "chokidar";
import { getConfig, generator } from "@tanstack/router-generator";
function watch() {
const configWatcher = chokidar.watch(
path.resolve(process.cwd(), "tsr.config.json")
);
function watch(root) {
const configWatcher = chokidar.watch(path.resolve(root, "tsr.config.json"));
let watcher = new chokidar.FSWatcher({});

@@ -17,3 +15,3 @@ const generatorWatcher = () => {

try {
await generator(config);
await generator(config, root);
} catch (err) {

@@ -26,3 +24,3 @@ console.error(err);

let timeout;
const deduped = (file) => {
const deduped = (_file) => {
if (timeout) {

@@ -29,0 +27,0 @@ clearTimeout(timeout);

{
"name": "@tanstack/router-cli",
"version": "1.85.10",
"version": "1.86.0",
"description": "Modern and scalable routing for React applications",

@@ -57,3 +57,3 @@ "author": "Tanner Linsley",

"yargs": "^17.7.2",
"@tanstack/router-generator": "^1.85.3"
"@tanstack/router-generator": "^1.86.0"
},

@@ -60,0 +60,0 @@ "devDependencies": {

import { generator } from '@tanstack/router-generator'
import type { Config } from '@tanstack/router-generator'
export async function generate(config: Config) {
export async function generate(config: Config, root: string) {
try {
await generator(config)
await generator(config, root)
process.exit(0)

@@ -8,0 +8,0 @@ } catch (err) {

@@ -15,3 +15,3 @@ import * as yargs from 'yargs'

const config = getConfig()
await generate(config)
await generate(config, process.cwd())
})

@@ -22,3 +22,3 @@ .command(

() => {
watch()
watch(process.cwd())
},

@@ -25,0 +25,0 @@ )

@@ -5,6 +5,4 @@ import path from 'node:path'

export function watch() {
const configWatcher = chokidar.watch(
path.resolve(process.cwd(), 'tsr.config.json'),
)
export function watch(root: string) {
const configWatcher = chokidar.watch(path.resolve(root, 'tsr.config.json'))

@@ -24,3 +22,3 @@ let watcher = new chokidar.FSWatcher({})

try {
await generator(config)
await generator(config, root)
} catch (err) {

@@ -36,3 +34,3 @@ console.error(err)

const deduped = (file: string) => {
const deduped = (_file: string) => {
if (timeout) {

@@ -39,0 +37,0 @@ clearTimeout(timeout)

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc