jQuery free #
In Drupal 8 we are still enjoying the availability of having jQuery at our disposal. This luxury puts us as frontend developers on an island if we look to the outside community. jQuery has had it’s use in the past, but to ship it on all projects nowadays, is more of an option than a rule.
Drupal Behaviours #
In custom modules, there is no Gulp-setup, so it means that these files won’t get linted, browserified, uglified and minified. All the processes that we have to unify our Frontend workflow is bypassed by having JS in custom modules.
Instead, create a new folder in the Compony theme and give it the same name as your custom module. Put the JS in that folder and attach the theme-library to it. You or your frontend-colleague will be thankful for when the client starts browsertesting.