@thelacanians/vue-native-cli 0.4.6 → 0.4.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cli.js CHANGED
@@ -10,7 +10,7 @@ import { join, dirname } from "path";
10
10
  import { fileURLToPath } from "url";
11
11
  import { existsSync } from "fs";
12
12
  import pc from "picocolors";
13
- var VERSION = "0.4.6";
13
+ var VERSION = "0.4.7";
14
14
  var createCommand = new Command("create").description("Create a new Vue Native project").argument("<name>", "project name").option("-t, --template <template>", "project template (blank, tabs, drawer)", "blank").action(async (name, options) => {
15
15
  const template = options.template;
16
16
  if (!["blank", "tabs", "drawer"].includes(template)) {
@@ -95,7 +95,7 @@ afterEvaluate {
95
95
  create<MavenPublication>("release") {
96
96
  groupId = "com.vuenative"
97
97
  artifactId = "core"
98
- version = "0.4.6"
98
+ version = "0.4.7"
99
99
  from(components["release"])
100
100
  }
101
101
  }
@@ -52,12 +52,14 @@ open class VueNativeViewController: UIViewController {
52
52
  super.viewDidLoad()
53
53
  view.backgroundColor = .systemBackground
54
54
 
55
- // Initialize bridge (registers __VN_flushOperations and sets the root VC)
56
- bridge.initialize(rootViewController: self)
57
-
58
- // Initialize JS engine (creates JSContext, registers polyfills)
55
+ // Initialize JS engine first (creates JSContext, registers polyfills).
56
+ // Bridge init MUST happen inside this callback so the JSContext exists
57
+ // when __VN_flushOperations is registered. Calling bridge.initialize()
58
+ // before this creates a nil-context registration that silently drops,
59
+ // causing a white screen.
59
60
  runtime.initialize { [weak self] in
60
61
  guard let self else { return }
62
+ self.bridge.initialize(rootViewController: self)
61
63
  DispatchQueue.main.async {
62
64
  self.loadBundle()
63
65
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thelacanians/vue-native-cli",
3
- "version": "0.4.6",
3
+ "version": "0.4.7",
4
4
  "description": "CLI for creating and running Vue Native apps",
5
5
  "license": "MIT",
6
6
  "author": "Vue Native Contributors",