Xo is experimental. The source is now public on GitHub, or try Xo in your browser.
Menu · XO1507

Docs

XO1507: an embed path leaves the module

error · reported by the checker

Embedded files must come from the module itself, so a build on another machine embeds the same bytes: paths are relative to the declaring file’s directory, stay inside it, and name no symbolic link.

Example

const KEY: Bytes = embed("../secrets/key.pem")

Fix

Move the file into the module, next to or below the declaring file.

Run xo explain XO1507 for this text in a terminal, or see section 10.6 of the specification.