T
TanStack4mo ago
foreign-sapphire

Buffer is not defined - from scroll restoration code

Hi, Im updating my TS Router version from 1.16.0 to latest and I'm running into the following issue: When I run my app, I get the following error:
jsesc.js:33 Uncaught ReferenceError: Buffer is not defined
at jsesc.js:33:18
at index.js:1:652
at ScriptOnce.tsx:32:1
at index.js:1:620
at scroll-restoration.tsx:29:1
at index.js:1:620
at Match.tsx:280:14
at index.js:1:620
at Matches.tsx:207:1
at index.js:1:620
jsesc.js:33 Uncaught ReferenceError: Buffer is not defined
at jsesc.js:33:18
at index.js:1:652
at ScriptOnce.tsx:32:1
at index.js:1:620
at scroll-restoration.tsx:29:1
at index.js:1:620
at Match.tsx:280:14
at index.js:1:620
at Matches.tsx:207:1
at index.js:1:620
I'm not using any scroll restoration features, and dont intend on using Start - just the Router I'm using ESBuild to bundle my app. Is there a way to get around this?
1 Reply
metropolitan-bronze
metropolitan-bronze4mo ago
this should not get executed on the client can you provide a complete minimal example?

Did you find this page helpful?