e0ipso / e0ipso/js_defer

Allow multiple queues

Open
#14 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
5
Forks
3
PR merge metrics
No merged PRs in 30d

Description

I'm reading the code in `js_defer_js_alter()`, and it seems like you can't really have more than one queue. For example, look at https://github.com/e0ipso/js_defer/blob/7.x-1.x/js_defer.module#L77-L84. That code is executed outside of the foreach loop, so the value of `$context` and `$deferred_info` will be set to whichever the last item in the array was. Perhaps I am reading it incorrectly?

Contributor guide

No contributing guide indexed for this repository

Research direction

Start in js_defer.module at js_defer_js_alter(), especially lines 77-84, and trace how $context and $deferred_info are assigned relative to the foreach loop. Reproduce or inspect behavior with more than one queue; done means each queue is handled independently rather than using only the last array item.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.