router-scroll location type breaks non-root routes in development
See original GitHub issueCreate new ember-cli app:
ember new router-scroll-test
cd router-scroll-test
- Remove
ember-welcome-page
addon ember generate route nested
- Add content to
app/templates/nested.hbs
ember serve
- Visit
localhost:4200/nested
(content loads fine)
Introduce ember-router-scroll:
ember install ember-router-scroll
- Follow README setup (import mixin into
router.js
; setlocationType: 'router-scroll'
) - Restart development server with
ember serve
- Visit
localhost:4200/nested
It seems that something in the 'router-scroll'
locationType is breaking the development express server’s ability to load the app directly into a non-root route. This is especially frustrating when livereload is constantly refreshing the page during development (triggering this error each time).
Issue Analytics
- State:
- Created 7 years ago
- Comments:12 (11 by maintainers)
Top Results From Across the Web
Handling scrolling on Angular router transitions - Medium
Perfectly handling scroll position upon Angular route transitions. Go from no handling at all to per-route declarative configuration.
Read more >Angular Tips: Understand Angular scroll position and ...
How to correctly handle scrolling upon Angular route transitions.
Read more >Migrating from Vue 2 - Vue Router
Reason: We use the history state to save information about the navigation like the scroll position, previous location, etc. routes option is required...
Read more >Page Not Found Error on Netlify Reactjs React Router solved
React Router handles routing on the client-side (browser) so when you visit the non-root page (e.g. https://yoursite.netlify.com/login ) ...
Read more >Learn React Router v6 In 45 Minutes - YouTube
FREE React Hooks Course: https://courses.webdevsimplified.com/react-hooks-simplifiedNearly every app in React needs to handle routing and by ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
https://github.com/dollarshaveclub/ember-router-scroll/pull/28 has the instructions in the readme. I’m having a hard time explaining how to concisely explain why that config is needed, so I just linked to the issue.
Hi @kpfefferle. Thanks for letting us know. I am able to reproduce it. @bcardarella is working with the ember team to get the router-scroll location API stuff into mainline ember, so I think after that, it might resolve itself, hopefully.