Conversation
|
The loading indicator can be changed by editing https://github.com/HubSpot/pace/tree/master/themes |
|
Hey @hatemhosny, that's a great PR. Could you re-do it to use npm for dependencies and not copying the 3rd party modules into the project? |
|
Thank you, @nnixaa. I have changed it to use pace-js npm package. |
|
@hatemhosny great! Sure, here are the steps:
That's it. This way your styles will be multiplied per each theme so that they will use the variables of the current enabled theme. |
|
Thank you, @nnixaa for the clear guide. I have done the suggested changes (I'm not sure why it does not show here). Notes: I use the theme variable I added to the other alternative would be adding let me know what you think |
|
done... I have commented it out, in case somebody wants to get it back. |
|
@hatemhosny awesome! Many thanks for this, merging now. Looking forward to new PRs 👍 |

What kind of change does this PR introduce?
Feature
What is the current behavior?
During navigation, there is no indicator that a network request is being made e.g API call or lazy loaded module. The user may think the app is not responding.
What is the new behavior (if this is a feature change)?
This is a an automatic loading progress bar and spinner using pace.js.
It works out of the box without the need for any manual configurations.
It automatically shows a loading progress indicator when a network request is made, without the need to explicitly call any code.
Other information:
pace.min.jsandpace-theme-flash.scssare placed in/assets/vendors/pace/and added to.angular-cli.jsonto be loaded by angular.the color of the indicator is set in
pace-theme-flash.scssusing the theme variablenb-theme(color-fg-highlight)refer to pace.js documentation for advanced configurations.