diff --git a/README.md b/README.md index 0ac9b1d..dde6c68 100644 --- a/README.md +++ b/README.md @@ -36,6 +36,13 @@ cache-busting, split chunks. ## Quick reference: +Add `manifest_loader` to your `INSTALLED_APPS` and: + +``` +STATICFILES_STORAGE = 'manifest_loader.storage.DjangoManifestLoaderStorage' +``` + + ### Manifest tag ```djangotemplate diff --git a/manifest_loader/storage.py b/manifest_loader/storage.py new file mode 100644 index 0000000..fc79768 --- /dev/null +++ b/manifest_loader/storage.py @@ -0,0 +1,8 @@ +from django.contrib.staticfiles.storage import ManifestStaticFilesStorage + + +class DjangoManifestLoaderStorage(ManifestStaticFilesStorage): + """ + If a file isn’t found in the staticfiles.json manifest at runtime, don't raise an exception + """ + manifest_strict = False