<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>timtoronto634</author_name>
  <author_url>https://blog.hatena.ne.jp/timtoronto634/</author_url>
  <blog_title>Progress of a2</blog_title>
  <blog_url>https://timtoronto634.hatenablog.com/</blog_url>
  <categories>
  </categories>
  <description>背景とか AI とか たまに Chrome 拡張開発をするのだが、その度に混乱することがある。 それが ESModule を使うのか CommonJS を使うのか、ということだ。 昨今は仕事でもプライベートは基本的に ESM を使っていて、 require なんて全く見なくなった。 だから油断すると import 文を書いてしまうわけだが、 Chrome 拡張機能においては Cannot use import statement outside a module というエラーに見舞われる。もはやトラウマものである。 error がたくさん出る この件を AI や AI Editor に聞いてみ…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Ftimtoronto634.hatenablog.com%2Fentry%2F2025%2F12%2F02%2F220700&quot; title=&quot;結局 Chrome 拡張では ESModule が使えるのか - Progress of a2&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url>https://cdn-ak.f.st-hatena.com/images/fotolife/t/timtoronto634/20251202/20251202215029.png</image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2025-12-02 22:07:00</published>
  <title>結局 Chrome 拡張では ESModule が使えるのか</title>
  <type>rich</type>
  <url>https://timtoronto634.hatenablog.com/entry/2025/12/02/220700</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
