tessl install tessl/npm-xmlhttprequest@1.8.0XMLHttpRequest for Node.js that emulates the browser XMLHttpRequest object
Agent Success
Agent success rate when using this tile
75%
Improvement
Agent success rate improvement when using this tile compared to baseline
1.15x
Baseline
Agent success rate without this tile
65%
A small utility for retrieving UTF-8 text from local files addressed by file:// URLs, supporting both asynchronous and synchronous reads.
file:// URL pointing to fixtures/greeting.txt containing Hello from file!, reading the file resolves with the exact contents as a string. @testfile:// URL for a missing file rejects with an Error whose message includes the requested file name. @testfixtures/short.txt via its file:// URL using the synchronous entry point returns the exact content string without involving promises. @test@generates
export async function readLocalFile(fileUrl: string): Promise<string>;
export function readLocalFileSync(fileUrl: string): string;Provides a browser-like request interface for HTTP(S) and local file URLs.