Details
-
Improvement
-
Status: Closed
-
High
-
Resolution: Fixed
-
5.0.2
-
None
-
None
-
Turing Sprint 175
Description
Sometimes a project wants to delay the JavaScript to call to render all the async HST Components [1] because they want to call some necessary AJAX calls before the asynchronous component rendering URLs are invoked. For example, they can establish some client information in those prior AJAX calls from their own analytic system and they want to pass along those established data in relevance when invoking the next Async component calls.
So, it would be nice if a project can customize the built-in system AJAX call to render the async component windows in a page.
For example, if they set somethings in hst-config.properties, they can possibly wrap the following built-in system ajax call [1] for custom behavior:
<script type="text/javascript"> //<![CDATA[ a425658310.b425658310.AsyncPage.load(); //]]> </script>
Examples:
# Default JavaScript code fragment template to load asynchronous components in a page on page loading time in SpringComponentManager.properties ajax.asynchronous.component.windows.load.js.fragment.template = {0}
# Example customization to wrap the default JavaScript fragment in java.text.MessageFormat format to render asynchronous components on page load. #ajax.asynchronous.component.windows.load.js.fragment.template = registerAsyncComponentsRenderingCallback(function() '{' {0} '}');