@tanstack/react-router 1.81.1 → 1.81.2

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tanstack/react-router",
3
- "version": "1.81.1",
3
+ "version": "1.81.2",
4
4
  "description": "Modern and scalable routing for React applications",
5
5
  "author": "Tanner Linsley",
6
6
  "license": "MIT",
@@ -50,11 +50,13 @@
50
50
  },
51
51
  "dependencies": {
52
52
  "@tanstack/react-store": "^0.5.6",
53
+ "jsesc": "^3.0.2",
53
54
  "tiny-invariant": "^1.3.3",
54
55
  "tiny-warning": "^1.0.3",
55
56
  "@tanstack/history": "1.61.1"
56
57
  },
57
58
  "devDependencies": {
59
+ "@types/jsesc": "^3.0.3",
58
60
  "@testing-library/jest-dom": "^6.6.3",
59
61
  "@testing-library/react": "^16.0.1",
60
62
  "@vitejs/plugin-react": "^4.3.3",
@@ -1,3 +1,5 @@
1
+ import jsesc from 'jsesc'
2
+
1
3
  export function ScriptOnce({
2
4
  className,
3
5
  children,
@@ -16,7 +18,8 @@ export function ScriptOnce({
16
18
  __html: [
17
19
  children,
18
20
  (log ?? true) && process.env.NODE_ENV === 'development'
19
- ? "console.info('Injected From Server:\\n" + children + "');"
21
+ ? `console.info(\`Injected From Server:
22
+ ${jsesc(children.toString(), { quotes: 'backtick' })}\`)`
20
23
  : '',
21
24
  ]
22
25
  .filter(Boolean)
package/src/router.ts CHANGED
@@ -2228,8 +2228,6 @@ export class Router<
2228
2228
  let pendingTimeout: ReturnType<typeof setTimeout>
2229
2229
 
2230
2230
  if (shouldPending) {
2231
- console.log('### 2186 setting timeout', pendingMs)
2232
-
2233
2231
  // If we might show a pending component, we need to wait for the
2234
2232
  // pending promise to resolve before we start showing that state
2235
2233
  pendingTimeout = setTimeout(() => {