How can I add CSS or JavaScript files?
Add a module, give it a libraries file (MODULE.libraries.yml):

global:
  js:
    /js.js: {}
  css:
    theme:
      /css.css: {}


In the .module file, implement hook_page_attachments:

function MODULE_page_attachments(array &amp;$attachments) {
  $attachments['#attached']['library'][] = 'MODULE/global';
}


When you enable the module (or clear cache if it's an existing module), the CSS and JS will be included on every page.