|
@@ -47,6 +47,8 @@ class Runner {
|
|
this.__whitelistApi(cfg, toml)
|
|
this.__whitelistApi(cfg, toml)
|
|
})
|
|
})
|
|
|
|
|
|
|
|
+ entry.generate(tauriDir, cfg)
|
|
|
|
+
|
|
const runningDevServer = devPath.startsWith('http')
|
|
const runningDevServer = devPath.startsWith('http')
|
|
let inlinedAssets: string[] = []
|
|
let inlinedAssets: string[] = []
|
|
|
|
|
|
@@ -56,8 +58,6 @@ class Runner {
|
|
|
|
|
|
process.env.TAURI_INLINED_ASSSTS = inlinedAssets.join('|')
|
|
process.env.TAURI_INLINED_ASSSTS = inlinedAssets.join('|')
|
|
|
|
|
|
- entry.generate(tauriDir, cfg)
|
|
|
|
-
|
|
|
|
this.devPath = devPath
|
|
this.devPath = devPath
|
|
|
|
|
|
const features = runningDevServer ? ['dev-server'] : []
|
|
const features = runningDevServer ? ['dev-server'] : []
|
|
@@ -121,11 +121,10 @@ class Runner {
|
|
this.__whitelistApi(cfg, toml)
|
|
this.__whitelistApi(cfg, toml)
|
|
})
|
|
})
|
|
|
|
|
|
- const inlinedAssets = await this.__parseHtml(cfg, cfg.build.distDir)
|
|
|
|
|
|
+ entry.generate(tauriDir, cfg)
|
|
|
|
|
|
|
|
+ const inlinedAssets = await this.__parseHtml(cfg, cfg.build.distDir)
|
|
process.env.TAURI_INLINED_ASSSTS = inlinedAssets.join('|')
|
|
process.env.TAURI_INLINED_ASSSTS = inlinedAssets.join('|')
|
|
-
|
|
|
|
- entry.generate(tauriDir, cfg)
|
|
|
|
|
|
|
|
const features = [
|
|
const features = [
|
|
cfg.tauri.embeddedServer.active ? 'embedded-server' : 'no-server'
|
|
cfg.tauri.embeddedServer.active ? 'embedded-server' : 'no-server'
|
|
@@ -163,7 +162,7 @@ class Runner {
|
|
const distIndexPath = path.join(indexDir, 'index.html')
|
|
const distIndexPath = path.join(indexDir, 'index.html')
|
|
if (!existsSync(distIndexPath)) {
|
|
if (!existsSync(distIndexPath)) {
|
|
warn(
|
|
warn(
|
|
- `Error: cannot find index.html in "${indexDir}". Did you forget to build your web code or update the build.distDir in tauri.conf.js?`
|
|
|
|
|
|
+ `Error: cannot find index.html in "${indexDir}". Did you forget to build your web code or update the build.distDir in tauri.conf.json?`
|
|
)
|
|
)
|
|
reject(new Error('Could not find index.html in dist dir.'))
|
|
reject(new Error('Could not find index.html in dist dir.'))
|
|
}
|
|
}
|