MCPcopy
hub / github.com/livebud/bud / Load

Function Load

package/svelte/compiler.go:19–25  ·  view source on GitHub ↗
(vm js.VM)

Source from the content-addressed store, hash-verified

17var compiler string
18
19func Load(vm js.VM) (*Compiler, error) {
20 if err := vm.Script("svelte/compiler.js", compiler); err != nil {
21 return nil, err
22 }
23 // TODO make dev configurable
24 return &Compiler{vm, true}, nil
25}
26
27type Compiler struct {
28 VM js.VM

Callers 13

TestServeFileFunction · 0.92
TestGenerateDirFunction · 0.92
TestUpdateFileFunction · 0.92
TestSvelteHelloFunction · 0.92
TestSvelteAwaitFunction · 0.92
TestSveltePropsFunction · 0.92
TestSvelteLocalImportsFunction · 0.92
TestUpdateFileFunction · 0.92
loadServerFunction · 0.92
TestSSRFunction · 0.92
TestSSRRecoveryFunction · 0.92
TestDOMFunction · 0.92

Calls 1

ScriptMethod · 0.65

Tested by 13

TestServeFileFunction · 0.74
TestGenerateDirFunction · 0.74
TestUpdateFileFunction · 0.74
TestSvelteHelloFunction · 0.74
TestSvelteAwaitFunction · 0.74
TestSveltePropsFunction · 0.74
TestSvelteLocalImportsFunction · 0.74
TestUpdateFileFunction · 0.74
loadServerFunction · 0.74
TestSSRFunction · 0.74
TestSSRRecoveryFunction · 0.74
TestDOMFunction · 0.74