Skip to content

CapacitorAdapter.readByUrl method

CapacitorAdapter › readByUrl

Unofficial

Reads a text file by fetching its resource URL, bypassing the HTTP cache. Used to load a community plugin's main.js, falling back to read.

Signature:

readByUrl(normalizedPath: string): Promise<null | string>

Parameters:

ParameterTypeDescription
normalizedPathstringThe path to read.

Returns: Promise<null | string> — A promise that resolves with the file content, or null when the fetch fails.