Cause: #1737148: Explicitly declare all JS dependencies, don't use drupal_add_js
#type machine_name doesn't work at all right now and throws a JS error instead.
Due to #1639012: Guard against broken behaviors I guess no one noticed yet, since the error is "nicely" hidden in the JS console and all other scripts/behaviors continue to work on the page. (In hindsight, was it a good idea to hide blatant JS errors...?)
I suspect the cause for this is that dependencies are not properly computed. Instead, they need to be manually specified for every single library that is defined. I already stated on the original JS dependencies issue that having to manually specify the entire dependency chain is a bad idea - that's what machines are for.
So we should
1) fix the missing dependency
2) make that machine compute dependencies for us (this can be deferred to a separate issue, but should at least be major)
Comment | File | Size | Author |
---|---|---|---|
#3 | 1776030_3.patch | 588 bytes | chx |
#1 | drupal8.machine-name.1.patch | 444 bytes | sun |
Comments
Comment #1
sunComment #2
chx CreditAttribution: chx commentedCorrect (note to committers: make very sure the patch applied to the drupal.machine-name array in system.module, there's not enough context for the patch utility).
Comment #3
chx CreditAttribution: chx commentedNote: this is absolutely not sun's fault, simply there are too many similar lines there. I am actually breaking core conventions here when reposting it with git diff -U6 but otherwise it could apply to something else.
Comment #4
webchickConfirmed with git diff --U=10, committed and pushed to 8.x. Thanks!
Agreed w/ the follow-up on 2). I'd also love a follow-up to get something like the Libraries API module test that tstoeckler describes at #1772466-3: Broke overlay with the dependency patch to get a basic sanity checking that these things are being loaded when they ought to be. This is the third or fourth time JS refactoring like this has caused such a regression.