trying to implement loading bar but it need an http request to work