mercredi 5 août 2020

Question about the Ember tutorial, why the link http://localhost:4200/rentals/grand-old-mansion does not work

I am learning ember now. I follow the tutorial to build a web app.

In part 2 of the tutorial, the Route Params section the URL as follow:

https://guides.emberjs.com/release/tutorial/part-2/route-params/

I found something strange.

The test case for the below link does not pass.

http://localhost:4200/rentals/grand-old-mansion

I found that if I click the link from the root (i.e. /), it can shows the rental correctly.

And then, if I refresh the page, it does not work. The error message as below:

Uncaught (in promise) Error: No model was found for 'rental' and no schema handles the type

I checked all files that do not have typo error. What is the problem?




Aucun commentaire:

Enregistrer un commentaire