mapboard icon indicating copy to clipboard operation
mapboard copied to clipboard

New data source type for transforming existing data

Open ajrothwell opened this issue 6 years ago • 0 comments

Use case: buffering parcel polygon for RCO notification radius.

This would be a new type of data source which does not fetch data form an API, but instead takes in-memory data and transforms it arbitrarily. In the config file this could look like:

    rcoNotificationBuffer: {
      type: 'transform',
      deps: ['parcels.pwd'],
      options: {
        transforms: ['buffer320Ft'],
      },
    },

where buffer320Ft is a transform defined in config.transforms. Currently the logic for applying transforms is located in TopicComponent.vue, so that would need to be extracted into a reusable util.

See the rco-notification-buffer branch for some initial work on this.

To pick this back up again: finalize the API for transform data sources (see rcoNotificationBuffer in the Polling example's config.js), and then make it work.

ajrothwell avatar Feb 28 '18 21:02 ajrothwell