adamchainz / djade

A Django template formatter.
MIT License
283 stars 4 forks source link

Linting breaks with `load X from Y` syntax #62

Closed ericholscher closed 1 month ago

ericholscher commented 1 month ago

Package Version

1.0

Description

We are trying to be more explicit with our imports, using things like:

{% load blocktrans trans from i18n %}

Djade rewrites this to:

{% load blocktrans from i18n trans %}
adamchainz commented 1 month ago

I forgot about this syntax!

ericholscher commented 1 month ago

I'm a little surprised it's not recommended, tbh. It's way more explicit, whereas the default is like doing import * everywhere. Very incongruous with the recommendations for writing Python code!