Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a warning when route.start is called multiple times #224

Closed
chasenlehara opened this issue Jan 9, 2019 · 1 comment
Closed

Add a warning when route.start is called multiple times #224

chasenlehara opened this issue Jan 9, 2019 · 1 comment

Comments

@chasenlehara
Copy link
Member

done-autorender automatically calls route.start() for you when it sets up your app’s view model. If you follow the can-route docs and call start yourself, your app won’t work because done-autorender will create a new route.data and call route.start() itself.

I think there are a couple possible warnings we could show that would help users understand this issue:

  1. Warn if route.start() gets called a second time without first having been torn down.
  2. Have done-autorender check whether start has already been called, and provide an error/warning if it has.
@chasenlehara
Copy link
Member Author

I’m closing this in favor of #153

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant