[solved] preloader cannot be closed immediately

If you open a preloader and then close immediately, it then cannot be closed.
https://jsfiddle.net/qdechochen/80nf31wr/

Here I open a preloader before an ajax request, and after get the data, close it. This cause problem when the request is very fast. Right now I have to do a setTimeout before close the preloader.

All modals are show within requestAnimation frame so you can use .nextFrame() util to hide it:
https://jsfiddle.net/85c9L3db/

this.$f7.dialog.preloader('canot hide sometimes');
this.$f7.utils.nextFrame(() => {
  this.$f7.dialog.close();
})

That works perfectly. thanks @nolimits4web