You must update the package.json file of the application to add the
shared library, @buc/svc-angular, as a dependency.
Procedure
- Add
@buc/svc-angular to the package.json file of the
application as a dependency. Here are two different ways to add the dependency.
The version of the @buc/svc-angular library is set to
"*" to point to the latest version that is uploaded to the
repository.
- Add the Angular library for conversions,
@ngx-translate/core, to the
package.json file of the application as a dependency. Here are two different
ways to add the dependency.
- If required, install all dependencies for your repository by using the following
command.
Add a start script to be used for serving the Angular
application.
- Define the following parameters for the
start script:
- --port <number>
- The port number entered in the URL for Local development mode url in the
Customization settings. For example, 9000.
- --ssl
- Ensures that the application is served over an HTTPS connection. This option is recommended for
secure deployment.
- --source-map
- Helps debug the application during local development.
- --base-href
- The context root for the application or the static part of the URL to access the application.
Note:
- This value must be consistent with the project name that you specified when you created the
Angular project in the procedure Base setup for Angular and mapping the hosts file.
- This value must correspond to the path provided or the first part of the path
after the protocol and host in the Local development mode url field in the
Settings > Customization page.
For example, for Local
development mode url given as
https://localhost:9000/buc-custom-app-starter and <project
name> as buc-custom-app-starter, the --base-href must be
specified as buc-custom-app-starter.
- --host=bucgenerichost
- The DEV tenant only supports connecting to a local server with the
hostname bucgenerichost.
Here is an example of the
start
script:
"start": "ng serve --port 9000 --ssl --source-map --host=bucgenerichost
--base-href=/buc-custom-app-starter/"
Ensure
that you use the same parameters when you add the feature through
Customization
settings in
Order Hub (
Settings >
Customization).
- Optional: It is recommended that you modify the existing
build entry to the following:
"build": "ng build --aot --prod"
- Ensure that
namein package.json corresponds to the
project name that you specified when you created the Angular
project in the procedure Base setup for Angular and mapping the hosts file. This value
also corresponds to --base-href in the start script.
What to do next
Important: Conventions for versioningOrder Hub
uses the following conventions of semantic versioning. It is recommended that you follow the same
conventions for versioning your applications to ensure consistency. For example, in this version
"1.2003.1":
1 - Major version. Represents technology or generation updates like changing
from Angular 8 to Angular 10.
2003 - Minor version. Corresponds to the year and month and is updated for each
monthly release. 2003 represents March 2020. Oct 2020 is given as 2010.
1 - Patch version. Increments for any changes, bug fixes, features, or patches
within a monthly release.