@magda/utils 3.0.1 → 3.0.2-alpha.1
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/dist/index.d.ts +12 -0
- package/dist/index.js +2971 -217
- package/package.json +3 -3
package/dist/index.d.ts
CHANGED
|
@@ -115,6 +115,18 @@ export declare function getRequest<T = any, CT = string>(url: string, noCache?:
|
|
|
115
115
|
|
|
116
116
|
export declare function getRequestNoCache<T = any, CT = string>(url: string, extraFetchOptions?: RequestInit): Promise<T>;
|
|
117
117
|
|
|
118
|
+
/**
|
|
119
|
+
* Get the access url of a storage api resource from [pseudo storage api resource URL](https://github.com/magda-io/magda/issues/3000)
|
|
120
|
+
* If the input url is not a pseudo storage api resource URL, return the input url directly
|
|
121
|
+
*
|
|
122
|
+
* @export
|
|
123
|
+
* @param {string} resourceUrl pseudo storage api resource URL or ordinary HTTP access url
|
|
124
|
+
* @param {string} storageApiBaseUrl storage api base url
|
|
125
|
+
* @param {string} datasetsBucket datasets storage bucket name
|
|
126
|
+
* @return {*}
|
|
127
|
+
*/
|
|
128
|
+
export declare function getStorageApiResourceAccessUrl(resourceUrl: string, storageApiBaseUrl: string, datasetsBucket: string): string;
|
|
129
|
+
|
|
118
130
|
export declare const isUuid: (id: any) => boolean;
|
|
119
131
|
|
|
120
132
|
declare class Maybe<T> implements Monad<T>, Functor<T>, Eq<Maybe<T>> {
|