I have found myself in a situation where i have broken up this complicated page into a number of customElements. However, one of those customElement’s viewmodel has a function that another viewmodel needs.
How do I use that viewmodel’s function to calculate a set of values in this other customElement? I tried adding function’s viewmodel.ref onto the customElement’s template but had little success.
Its not clear how to share bits of code across individual components/customElements… Can someone outline the normal way you might share a bit of code, say a function and variables etc
Would appreciate some insight… Cheers Simon