Routes in Firefly webapps | Community
Skip to main content
Adobe Employee
September 21, 2020
Question

Routes in Firefly webapps

  • September 21, 2020
  • 1 reply
  • 3104 views

I have a simple webapp and have used react router, however within the application the url changes to the route part which is not found by firefly.

Here is the webapp with links

 

 

 

 

<Router> <div> <ul> <li> <Link to='/'>Home</Link> </li> <li> <Link to='/button'>Button</Link> </li> </ul> <hr /> <Switch> <Route exact path='/'> <Home/> </Route> <Route path='/button'> <ButtonDemo /> </Route> </Switch> </div> </Router>

 

 

 

 

The URL on navigation is https://experience.adobe.com/?devMode=true#/@ags1008/custom-apps/button which results

in Error 408 Request Timeout.

 

Any recommendation on how to achieve this navigation.

 

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

1 reply

Adobe Employee
September 21, 2020

Hi @harpreet_ahluwa - in the latest CLI release we enhanced the web UI template with react router. Please update your CLI `npm install -g @adobe/aio-cli` and try creating a new app with web assets.

Adobe Employee
September 23, 2020
Hi @harpreet_ahluwa - sorry I was using a pre-release version of the app plugin which is yet to be included in the aio-cli core packages. But you could try it today by installing the new app plugin version `aio plugins install @61380/aio-cli-plugin-app@4.0.0` (but remember to uninstall it when this version makes it to the core). Then you will have the new UI with `app init` or `app add web-assets`.