Commit e780283
committed
Don't require ActionView::Base when rake tasks get loaded:
- ### Problem
When running any rake command, Sprockets Rails will autoload
`ActionView::Base` way too early. This creates a broader issue
which I described in detail in rails/rails#38024
### Solution
This `require` statement was the last attempt to fix a old [issue](rails/rails#9461)
in 2014. TL;DR on the issue is that assets_prefix would
get ignored when precompiling assets.
A lot has change since 2014 in sprockets-rails and after digging
I can confirm that requiring AV::Base is no longer needed.
We don't need it to run assets related rake tasks.
This is thanks thanks of the decoupling between
`Sprockets::Rails::Context` and `Sprockets::Rails::Helper`
in 32a58f541 parent 5f75d41 commit e780283
2 files changed
+4
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
6 | 5 | | |
7 | 6 | | |
8 | 7 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
40 | | - | |
41 | 40 | | |
42 | 41 | | |
43 | 42 | | |
| |||
330 | 329 | | |
331 | 330 | | |
332 | 331 | | |
333 | | - | |
| 332 | + | |
334 | 333 | | |
335 | 334 | | |
336 | 335 | | |
337 | 336 | | |
338 | | - | |
| 337 | + | |
339 | 338 | | |
340 | 339 | | |
341 | 340 | | |
| |||
346 | 345 | | |
347 | 346 | | |
348 | 347 | | |
| 348 | + | |
| 349 | + | |
349 | 350 | | |
350 | 351 | | |
351 | 352 | | |
| |||
0 commit comments