Load Improv later

This commit is contained in:
Paulus Schoutsen 2021-06-07 05:37:02 +00:00
parent 4d99fcfa9b
commit 97fa24e668
2 changed files with 9 additions and 13 deletions

8
package-lock.json generated
View File

@ -1,12 +1,11 @@
{
"name": "esp-web-tools",
"version": "1.0.0",
"version": "2.0.1",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "esp-web-tools",
"version": "1.0.0",
"version": "2.0.1",
"license": "Apache-2.0",
"dependencies": {
"@material/mwc-button": "^0.21.0",
@ -1223,9 +1222,6 @@
"resolved": "https://registry.npmjs.org/rollup/-/rollup-2.50.5.tgz",
"integrity": "sha512-Ztz4NurU2LbS3Jn5rlhnYv35z6pkjBUmYKr94fOBIKINKRO6kug9NTFHArT7jqwMP2kqEZ39jJuEtkk91NBltQ==",
"dev": true,
"dependencies": {
"fsevents": "~2.3.1"
},
"bin": {
"rollup": "dist/bin/rollup"
},

View File

@ -97,12 +97,6 @@ export const startFlash = async (
return resp.arrayBuffer();
});
// Pre-load improv for later
if (build.improv) {
// @ts-ignore
import("https://www.improv-wifi.com/sdk-js/launch-button.js");
}
// Run the stub while we wait for files to download
const espStub = await esploader.runStub();
@ -123,9 +117,15 @@ export const startFlash = async (
logEl.addRow({
id: "preparing",
content: `Ready to install`,
content: `Installation prepared`,
});
// Pre-load improv for later
if (build.improv) {
// @ts-ignore
import("https://www.improv-wifi.com/sdk-js/launch-button.js");
}
if (eraseFirst) {
logEl.addRow({
id: "erase",