Skip to content

hiiu overlay

Print the interception files that make every outbound request a recorded refusal. It prints and never writes.

hiiu overlay [path]

Prints the interception overlay: the generated files that make every request leaving the app a recorded refusal unless it goes to loopback.

It prints and never writes. hiiu build is the writer. Same constraints as the other read-only commands, and two runs of one input are byte-identical.

Arguments and flags

[path] The repo or app directory to generate an overlay for. Default .
--decisions <file> The confirmed decisions document to generate against

Every global flag also applies.

Why you would run it

To read what hiiu is about to inject into a copy of your app before letting it, and to see which requests the overlay can and cannot cover on your framework.

The Next.js warning

A Next.js app's browser-originated requests are not intercepted, because Next has no supported hook that runs a module before client application code. Server-side requests, meaning server components, route handlers and generateStaticParams, are covered.

That is a stderr warning and exit 0, not a failure. A target hiiu cannot intercept at all is exit 3 with UNSUPPORTED_TARGET.

Exit codes

Code When
0 Printed, warnings included
3 Not a supported frontend app, or UNSUPPORTED_TARGET

Example

hiiu overlay --json | jq '.files[].path'