You'll noticeTier: how much it should matter to you
3Useful: my rating, 1 to 5
3Signal: worth watching, 1 to 5
HooksArea: what it touches
ImprovementsKind: in v2.1.287,
ImprovementsSection of the release
Unclear It is not clear whether hooks modules themselves are generally available or limited by a switch.
What
A hooks module is a code file that defines hooks, scripts that run automatically at set points. Claude Code now refuses a hooks module that loads other files with import(), a way of loading code while the program is running. The message tells the author to import their own files with an import declaration at the top of the file instead, such as import { name } from "./file.js".
Why
A hooks module that uses import() will be refused, so anyone writing one needs to switch to import declarations.
How sure we are
Something disagreesSomething we can check disagrees with this entry, or the writer said they could not settle it.
The writer flagged doubtIt is not clear whether hooks modules themselves are generally available or limited by a switch.