File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -144,6 +144,27 @@ configuration. The following two statements are equivalent:
144
144
For a list of available settings, see the full
145
145
:ref: `webassets documentation <webassets:environment-configuration >`.
146
146
147
+ Babel Configuration
148
+ ~~~~~~~~~~~~~~~~~~~
149
+
150
+ If you use `Babel `_ for internationalization, then you will need to
151
+ add the extension to your babel configuration file
152
+ as ``webassets.ext.jinja2.AssetsExtension ``
153
+
154
+ Otherwise, babel will not extract strings from any templates that
155
+ include an ``assets `` tag.
156
+
157
+ Here is an example ``babel.cfg ``:
158
+
159
+ .. code-block :: python
160
+
161
+ [python: ** .py]
162
+ [jinja2: ** .html]
163
+ extensions= jinja2.ext.autoescape,jinja2.ext.with_,webassets.ext.jinja2.AssetsExtension
164
+
165
+
166
+ .. _Babel : http://babel.edgewall.org/
167
+
147
168
148
169
Management Command
149
170 ------------------
You can’t perform that action at this time.
0 commit comments