The CreatorCon Call for Content is officially open! Get started here.

Use of Formatter for Chat Box in Custom Form and UI Builder – Best Practice and Version Impact

Srijan Mal
Tera Contributor

Hi all,

I wanted to share an update regarding the implementation of a chat box feature in our custom form using a formatter in ServiceNow.

As part of the client requirement, I initially used a formatter to embed the chat box within a custom form. This approach worked well and provided the desired user experience. Now, I am planning to reuse the same formatter within UI Builder to maintain consistency and fulfill the extended requirement.

From a best practice standpoint, using a formatter for such UI customization is acceptable, especially when dealing with legacy forms or when rapid prototyping is needed. However, for UI Builder, which is designed to leverage the Now Experience framework, it’s generally recommended to use components or custom web components instead of formatters, as they offer better performance, maintainability, and alignment with ServiceNow’s modern architecture.

Additionally, I’d like to highlight a potential impact due to version upgrade from Xandu to Zurich:

  • Formatter Behavior: Formatters may behave differently or become deprecated in newer versions like Zurich. ServiceNow is gradually moving away from legacy UI elements in favor of Now Experience components.
  • Compatibility: Custom formatters might require updates to remain compatible with Zurich, especially if they rely on DOM manipulation or older APIs.
  • UI Builder Integration: Zurich enhances UI Builder capabilities, and using formatters might limit access to newer features like data binding, event handling, and responsive layouts.

To ensure long-term stability and scalability, it might be worth considering a migration of the formatter logic into a custom component built using the Now Experience UI Framework.

Let me know if you'd like me to explore that path or assist with testing the formatter in Zurich.

Best regards,
Srijan Mal

0 REPLIES 0