chore: expose HMR option, add disclaimer to compiler options UI (#12386)

* chore: expose HMR option, add disclaimer to compiler options UI

* ok prettier whatever you say
pull/12387/head
Rich Harris 1 year ago committed by GitHub
parent f3f4ce5741
commit d9860941eb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -33,9 +33,22 @@
<Checkbox bind:checked={$compile_options.dev} />
<span class="boolean">{$compile_options.dev}</span>,
</label>
<label class="option">
<span class="key">hmr:</span>
<Checkbox bind:checked={$compile_options.hmr} />
<span class="boolean">{$compile_options.hmr}</span>,
</label>
});
</div>
<div class="note">
<p>
note: these options affect the JS output tab, but not the bundle that executes in the Result
tab.
</p>
</div>
<style>
.options {
padding: 0 10px;
@ -132,4 +145,13 @@
border: 1px solid var(--sk-theme-2);
transition: box-shadow 0.2s ease-out;
}
.note {
padding: 10px;
}
.note p {
font-size: 1.4rem;
text-wrap: balance;
}
</style>

@ -78,6 +78,7 @@
const DEFAULT_COMPILE_OPTIONS = {
generate: 'client',
dev: false,
hmr: false,
css: 'external'
};

Loading…
Cancel
Save