will be to have a standard template for all differ components which each represent one technical formular for calcultion. So the feeling and handling of the webpage on all calculation will be the same. But sometimes more expainations are needed or the kind of input methode will be a little bit differ as for the most values. Therefore a additional html template is needed. Now I am looking for the best way to bind the variables of the component with the both templates. In the moment, the same variable value is represented on both html pages and the sub-routines running on the main and same component.ts, but each html page will have differ values of the same variable!? The variable values are wrapped by an object (variablebuilder), the the properties are signals() (e.g. nominalValue()).
PS W:> git clone https://github.com/angulartool-de/TwoHtmlTemplatesOnOneComponent.git
then
PS W:> cd TwoHtmlTemplatesOnOneComponent
PS W:\TwoHtmlTemplatesOnOneComponent> pnpm update
as the angular references have to been installed.
This project was generated with Angular CLI version 17.0.8.
Run ng serve
for a dev server. Navigate to http://localhost:4200/
. The application will automatically reload if you change any of the source files.
Run ng generate component component-name
to generate a new component. You can also use ng generate directive|pipe|service|class|guard|interface|enum|module
.
Run ng build
to build the project. The build artifacts will be stored in the dist/
directory.
Run ng test
to execute the unit tests via Karma.
Run ng e2e
to execute the end-to-end tests via a platform of your choice. To use this command, you need to first add a package that implements end-to-end testing capabilities.
To get more help on the Angular CLI use ng help
or go check out the Angular CLI Overview and Command Reference page.