Skip to content

Commit a119b61

Browse files
committed
Adds changelog for version 1.3.0
1 parent fffb889 commit a119b61

File tree

3 files changed

+52
-5
lines changed

3 files changed

+52
-5
lines changed

CHANGELOG.md

+9-2
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,15 @@ For more general information, view the [readme](README.md).
55
Releases are added to the
66
[github release page](https://github.com/ezhome/django-webpack-loader/releases).
77

8-
## Unreleased
9-
- Applies ignore rule before checking assets
8+
## [1.3.0] -- 2021-08-30
9+
10+
- Add option for rel="preload" in JS/CSS tags #203
11+
- Add option for extension appending in the url files #135
12+
- Fixes RemovedInDjango41Warning #290
13+
- Applies IGNORE setting before checking assets #286
14+
- Removed type from link and script tags per #152
15+
16+
NOTE: Skipped version 1.2.0 to match `webpack-bundle-tracker` version
1017

1118

1219
## [1.1.0] -- 2021-06-18

README.md

+42-2
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,48 @@ INSTALLED_APPS = (
260260
</head>
261261
```
262262
263-
<br>
263+
### Preload
264+
265+
The `is_preload=True` option in the `render_bundle` template tag can be used to add `rel="preload"` link tags.
266+
267+
```HTML+Django
268+
{% load render_bundle from webpack_loader %}
269+
270+
<html>
271+
<head>
272+
{% render_bundle 'main' 'css' is_preload=True %}
273+
{% render_bundle 'main' 'js' is_preload=True %}
274+
275+
{% render_bundle 'main' 'css' %}
276+
</head>
277+
278+
<body>
279+
{% render_bundle 'main' 'js' %}
280+
</body>
281+
</html>
282+
```
283+
284+
### Appending file extensions
285+
286+
The `suffix` option can be used to append a string at the end of the file URL. For instance, it can be used if your webpack configuration emits compressed `.gz` files.
287+
288+
qwe
289+
```HTML+Django
290+
{% load render_bundle from webpack_loader %}
291+
292+
<html>
293+
<head>
294+
<meta charset="UTF-8">
295+
<title>Example</title>
296+
{% render_bundle 'main' 'css' %}
297+
</head>
298+
299+
<body>
300+
{% render_bundle 'main' 'js' suffix='.gz' %}
301+
</body>
302+
</html>
303+
```
304+
264305
265306
266307
### Multiple webpack projects
@@ -299,7 +340,6 @@ WEBPACK_LOADER = {
299340
300341
<!-- add some extra attributes to the tag -->
301342
{% render_bundle 'main' 'js' 'DEFAULT' attrs='async charset="UTF-8"'%}
302-
{% render_bundle 'main' 'js' 'DEFAULT' attrs='async charset="UTF-8"' suffix=".gz" %}
303343
</body>
304344
</head>
305345
```

tests/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
"react": "^16.0.0",
1616
"webpack": "^4.0.0",
1717
"compression-webpack-plugin": "^6.1.1",
18-
"webpack-bundle-tracker": "1.2.0",
18+
"webpack-bundle-tracker": "1.3.0",
1919
"webpack-cli": "^3.3.10",
2020
"webpack-dev-server": "^3.0.0"
2121
}

0 commit comments

Comments
 (0)