<commit_before>(async () => {
  'use strict';

  const { syntaxTheme = 'default' } = await browser.storage.sync.get('syntaxTheme');

  const isHtml = document.contentType === 'text/html';
  const pre = document.querySelector('body > pre:first-child');
  if (!isHtml && pre) {
    const fragment = document.createDocumentFragment();
    // Append css
    [
      browser.extension.getURL(`resources/lib/highlightjs/styles/${syntaxTheme}.css`),
      browser.extension.getURL('resources/css/style.css')
    ].forEach(path => {
      const css = document.createElement('link');
      css.rel = 'stylesheet';
      css.href = path;
      fragment.appendChild(css);
    });
    // Append js
    [
      browser.extension.getURL('resources/lib/highlightjs/highlight.pack.min.js'),
      browser.extension.getURL('resources/js/script.js')
    ].forEach(path => {
      const js = document.createElement('script');
      js.type = 'text/javascript';
      js.charset = 'utf-8';
      js.src = path;
      js.async = true;
      fragment.appendChild(js);
    });

    // Append to head
    document.head.appendChild(fragment);
  }
})();<commit_msg>use runtime.getURL instead of extension.getURL<commit_after>(async () => {
  'use strict';

  const { syntaxTheme = 'default' } = await browser.storage.sync.get('syntaxTheme');

  const isHtml = document.contentType === 'text/html';
  const pre = document.querySelector('body > pre:first-child');
  if (!isHtml && pre) {
    const fragment = document.createDocumentFragment();
    // Append css
    [
      browser.runtime.getURL(`resources/lib/highlightjs/styles/${syntaxTheme}.css`),
      browser.runtime.getURL('resources/css/style.css')
    ].forEach(path => {
      const css = document.createElement('link');
      css.rel = 'stylesheet';
      css.href = path;
      fragment.appendChild(css);
    });
    // Append js
    [
      browser.runtime.getURL('resources/lib/highlightjs/highlight.pack.min.js'),
      browser.runtime.getURL('resources/js/script.js')
    ].forEach(path => {
      const js = document.createElement('script');
      js.type = 'text/javascript';
      js.charset = 'utf-8';
      js.src = path;
      js.async = true;
      fragment.appendChild(js);
    });

    // Append to head
    document.head.appendChild(fragment);
  }
})();
{'fraction_non_alphanumeric': 0.16326530612244897, 'fraction_numerical': 0.0008684324793747286, 'mean_word_length': 2.9519725557461407, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6147196', 'n_tokens_mistral': 691, 'n_tokens_neox': 682, 'n_words': 116}