I need some guidance how to proceed the best way. Switching from c++ to canjs comes with a steep learning curve
What I'd like to do:
I have my data model structure figured out and want to reuse it in different screens of my application. For each screen I want to have a separate html,css and js file to make sure I don't create memory leaks etc. Have to figure that out later if really necessary to have all screens in one file.
Now in c++ I would simply put in an include statement for my .h file. Not existing in js and nodejs to my knowledge.
So I dug through the docs and came up with two possible solutions.
a) create my own nodejs-module (how do I do this when I need canMap and canList available)
b) Create a separate can.component which I can reuse (found this in the docs for canjs 2.3 though, so is this still valid?)
Do you know of a third and maybe better solution? If not, which route should I take.