Pui.show()

Hi there,

I noticed that in the stateless-rich-display sample app, it specifies a path of display on the pui.show() call. Can anyone explain what display does? The actual path of the display file is public/app.json, so I’m guessing that display has a special meaning – but there’s nothing written in the pui.show() documentation about this.

Here’s the code:

  pui.show({
    path: "display",
    screen: "main",    
    data: {
      employees: app.employees,
      offices: app.offices
    }
  });

And here’s the workspace file layout:

image

Thanks!

1 Like

Jeff,

Thanks for your question. In the case of this example, “display” is actually a web service name in the space. If you look at the icon for app.json, it is a green cloud with a cog. This indicates that it is a callable service. If you right click it and go to properties, you will see that the web service option is checked.

image

Also, on the Route Path property, the URL of the service is set to “display”. That is what is linking it together.

I will let our dev team know that they should clarify the readme file for this template.

Thank you again for using noderun!

1 Like

Thank you, that totally makes sense.

Maybe a nice addition would be a tooltip that shows what the route path is when you hover over any web service file.

1 Like