MCPcopy Create free account
hub / github.com/arktypeio/arktype / setEnvironment

Function setEnvironment

ark/aot/unplugin.ts:242–251  ·  view source on GitHub ↗
(bundlerEnvironment: Environment)

Source from the content-addressed store, hash-verified

240 restart()
241 }
242 const setEnvironment = (bundlerEnvironment: Environment) => {
243 // compilers sharing the plugin, as Rsbuild's environments do, that
244 // build one for a browser and one for a server share its worker, so
245 // what loads the bundle is unknown
246 environment =
247 environment && environment.browser !== bundlerEnvironment.browser ?
248 { ...bundlerEnvironment, browser: undefined }
249 : bundlerEnvironment
250 updateWorker()
251 }
252 // a changed file or configuration may need a new worker
253 const reset = () => {
254 checkSettings()

Callers 2

applyRspackFunction · 0.85
unplugin.tsFile · 0.85

Calls 1

updateWorkerFunction · 0.85

Tested by

no test coverage detected