0
Declined

Component

Sorbodoekje 4 weeks ago in Ideas updated 3 weeks ago 11

It would be nice, to be able to build a component, just like in c#, which can be re-used with parameters etc. That would save quite some development time. And it will prevent bugs, because I can spend my time one time on making a good component and then re-use it everywhere


Waiting for user's reply

Hello

You can create your own JS driver and reuse it in your projects. How does this differ from your definition of a component?

No that is not what I mean. I mean a graphic component. 

Example:

This component (from a SCADA platform), can attach some values, i.e. Apparent Wind Angle, True Wind Angle, Heading, etc. This component is used on multiple pages. Only parameters to modify is the type and value. No extra code is needed, because that runs in its component. 

And if you make it possible to make a password protected component, then it is possible for third parties to sell their components.

In C# they call it a control BTW.

Declined

This is impossible for the current architecture from the point of view of isolating such a component (if it is not written by us in native code) and it is basically impossible for C # in mobile applications (code must be compiled before execution).


Your task of reuse is completely solved by the JS script and the selection of a pop-up with elements in a separate project, which you can merge as needed.

It did not meant that the code should be written in C#. I meant a component made in javascript, which can be re-used, in the same way as you put buttons and labels in the GUI.

Disadvantage of merging elements, is that it will become difficult if afterwards a client wants to modify such a componant. Then after merging, the modification needs to be done for each mergen component.

You can create all graphics from a script, i.e. you will have one JS file that you can update (modify) and a separate definition class (constructor) that will allow you to use this component in the right place.

Exactly that's a method, for everything is a solution in Javascript, but wouldn't it be much better if you could do this in the GUI?

I really don't understand you ((

Create a separate project with the desired popup and draw your component. With a project merge, you can reuse it. If you need additional logic, then you can use the script, if not, then only the interface. You can copy as many of these items as you like.

What confuses you about this option? What is the main purpose of such components for you?

Sorry for being confusing. I mean that when you design a component and merge it into the project, you will will have i.e. 100 times the same component on several pages. Then my clients says I want to change the component i.e. different type of border. Then I will have to change this 100 times in my project.

For this case, the best would be to use the JS template, as I described above. For simplicity, you can draw a popup template in the editor, but clone and define links later in the script. Then changing the popup in one place will automatically change the behavior in the entire project.

OK I will give it a try. I didn't know that cloning a templete would work in this way. 

Sorry it took a while. But is it possible that this functionality got lost because of the latest updates? I watched a tutorial on Youtube, describing how to merge projects. But every time, when I open an additional project, it will be show in the top tab row, but not additionally in the project tree. So I will never get the option to merge the projects.