(root: string, opts: PrecompilePluginOptions)
| 101 | // one for each project and option set, kept from build to build so an answer |
| 102 | // Turbopack's cache holds a module's output against stays the file it read |
| 103 | const programDirOf = (root: string, opts: PrecompilePluginOptions): string => { |
| 104 | const normalized = |
| 105 | opts.cwd !== undefined && realPathOf(opts.cwd) === realPathOf(root) ? |
| 106 | (({ cwd: _, ...rest }) => rest)(opts) |
| 107 | : opts |
| 108 | return join(programsDirOf(root), hashOf(JSON.stringify(normalized))) |
| 109 | } |
| 110 | |
| 111 | export const doneFileOf = (dir: string): string => join(dir, "done.json") |
| 112 |
no test coverage detected