-
-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: fix playgrounds on Stackblitz (#39)
* polyfill * nextjs issues * docs
- Loading branch information
Showing
14 changed files
with
132 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { File } from 'node:buffer' | ||
|
||
/** | ||
* This file aims to polyfill missing APIs in Node.js 18 that oRPC depends on. | ||
* | ||
* Since Stackblitz runs on Node.js 18, these polyfills ensure oRPC works in that environment. | ||
* If you're running oRPC locally, please use Node.js 20 or later for full compatibility. | ||
*/ | ||
|
||
/** | ||
* Note: Stackblitz provides an emulated Node.js environment with inherent limitations. | ||
* If you encounter issues, please test on a local setup with Node.js 20 or later before reporting them. | ||
*/ | ||
|
||
/** | ||
* The `oz.file()` schema depends on the `File` API. | ||
* If you're not using `oz.file()`, you can safely remove this polyfill. | ||
*/ | ||
if (typeof globalThis.File === 'undefined') { | ||
globalThis.File = File as any | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { File } from 'node:buffer' | ||
|
||
/** | ||
* This file aims to polyfill missing APIs in Node.js 18 that oRPC depends on. | ||
* | ||
* Since Stackblitz runs on Node.js 18, these polyfills ensure oRPC works in that environment. | ||
* If you're running oRPC locally, please use Node.js 20 or later for full compatibility. | ||
*/ | ||
|
||
/** | ||
* Note: Stackblitz provides an emulated Node.js environment with inherent limitations. | ||
* If you encounter issues, please test on a local setup with Node.js 20 or later before reporting them. | ||
*/ | ||
|
||
/** | ||
* The `oz.file()` schema depends on the `File` API. | ||
* If you're not using `oz.file()`, you can safely remove this polyfill. | ||
*/ | ||
if (typeof globalThis.File === 'undefined') { | ||
globalThis.File = File as any | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { File } from 'node:buffer' | ||
|
||
/** | ||
* This file aims to polyfill missing APIs in Node.js 18 that oRPC depends on. | ||
* | ||
* Since Stackblitz runs on Node.js 18, these polyfills ensure oRPC works in that environment. | ||
* If you're running oRPC locally, please use Node.js 20 or later for full compatibility. | ||
*/ | ||
|
||
/** | ||
* Note: Stackblitz provides an emulated Node.js environment with inherent limitations. | ||
* If you encounter issues, please test on a local setup with Node.js 20 or later before reporting them. | ||
*/ | ||
|
||
/** | ||
* The `oz.file()` schema depends on the `File` API. | ||
* If you're not using `oz.file()`, you can safely remove this polyfill. | ||
*/ | ||
if (typeof globalThis.File === 'undefined') { | ||
globalThis.File = File as any | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { File } from 'node:buffer' | ||
|
||
/** | ||
* This file aims to polyfill missing APIs in Node.js 18 that oRPC depends on. | ||
* | ||
* Since Stackblitz runs on Node.js 18, these polyfills ensure oRPC works in that environment. | ||
* If you're running oRPC locally, please use Node.js 20 or later for full compatibility. | ||
*/ | ||
|
||
/** | ||
* Note: Stackblitz provides an emulated Node.js environment with inherent limitations. | ||
* If you encounter issues, please test on a local setup with Node.js 20 or later before reporting them. | ||
*/ | ||
|
||
/** | ||
* The `oz.file()` schema depends on the `File` API. | ||
* If you're not using `oz.file()`, you can safely remove this polyfill. | ||
*/ | ||
if (typeof globalThis.File === 'undefined') { | ||
globalThis.File = File as any | ||
} |