Note that it's a good idea to use the router with the hash param set to true as github pages doesn't support the redirect to index.html:
RouterModule.forRoot(routes, { useHash: true })
Thank you @Maxime for your nice idea, also you can copy the index.html to 404.html by Travis CI.
I just add this line to .travis.yml file in script section:
- cp index.html 404.html
Then the issues was solved.
My edited .travis.yml
You can see it in action.
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Note that it's a good idea to use the router with the hash param set to true as github pages doesn't support the redirect to index.html:
RouterModule.forRoot(routes, { useHash: true })
Thank you @Maxime for your nice idea, also you can copy the index.html to 404.html by Travis CI.
I just add this line to .travis.yml file in script section:
Then the issues was solved.
My edited .travis.yml
You can see it in action.