Nunjucks uses getTemplate() to preload and precompile templates -
env.getTemplate('page.html', true);
Documentation says also "If using any async loaders, you must use the async API." but there's no any code example. Can anyone tell what to use instead of getTemplate for async preload?
From their docs:
Just add an async: true property to your loader and it will be used asynchronously.
https://mozilla.github.io/nunjucks/api.html#asynchronous