magda-io / magda-preview-map

Catalog-based web geospatial visualisation platform.
http://terria.io
Other
1 stars 0 forks source link

Send Error Message back via postMessage in MagdaCatalogItem #14

Closed t83714 closed 3 years ago

t83714 commented 3 years ago

Send Error Message back via postMessage in MagdaCatalogItem

Currently, the Terria map only postMessage when loading is successfully done.

We should capture all errors in MagdaCatalogItem and send error back via postMessage.

This will provide an interface for Magda web client to handle error properly.

The string data send back for this case will be in JSON format.

And with the following type:

{
   type: "error";
   title: string; // might be empty string
   message: string;
}
t83714 commented 3 years ago

closed via PR: https://github.com/magda-io/magda-preview-map/pull/13