Is it possible to configure the Servicenow page so that all routines are processed by the root page?

Given a simple page created in Servicenow with the following configuration:

Name: My Page Url Suffix: my-page Layout: foo 

Inside foo, I load a one-page application with various routes, such as / invoice / 1, invoice / 2, user / 1, user / 2, etc.

I use react router for this routing, and although it supports hash routing freely, it clearly says that it is considered for "old browsers". And as of 2.4.1 it seems that having _key= is a requirement.

In any case, ideally, I don’t want to abuse the hashbangs to describe the route, instead I use a more typical URL structure.

Current:

 instance.servicenow/my-page#/invoice/1 

Preferably:

 instance.servicenow/my-page/invoice/1 

This will require SNs to know that anything deeper than my-page should be redirected to my page. I came from the world of Apaches, and in this case I would simply write the following:

 RewriteEngine On RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} -f [OR] RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} -d RewriteRule ^ - [L] RewriteRule ^ /index.html [L] 
+5
source share

All Articles