Embeded Angular component app

Highlighted
Shopify Partner
1 0 0

Hi,

I would like to make a ui  embeded angular component app that listen and react to Shopify events.

For example to have angular panel in a Shopify shop that listen to check out event and react when the end user purchase something.

I believe It should be in a form of Shopify app.

Is it possibly ? Does is make sense? Do I use embeded sdk ? what is the general process?

 

Thanks

0 Likes
Highlighted
Shopify Partner
1 0 0

I recently solved a similar problem in React. This thread helped me realize the solution is to set up an event bus. I used Postal.js to send data into the component. You could attach a click listener to the checkout button that sends a postal event. Then in your component subscribe to window.postal.

I'm very familiar with RxJS but I think it makes sense in your situation. It does require familiarity with Functional Reactive Programming patterns but I think NG-2 has excellent support for consuming event streams

Hope this helps ^_^

0 Likes