@basthon/kernel-base 0.36.10 → 0.38.0

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/lib/kernel.d.ts CHANGED
@@ -4,6 +4,7 @@
4
4
  */
5
5
  export declare class KernelBase {
6
6
  private _rootPath;
7
+ private _ready;
7
8
  private readonly _loaded;
8
9
  private readonly _pageLoad;
9
10
  execution_count: number;
@@ -49,6 +50,10 @@ export declare class KernelBase {
49
50
  * Initialize the kernel.
50
51
  */
51
52
  init(): Promise<void>;
53
+ /**
54
+ * Is the kernel ready?
55
+ */
56
+ get ready(): boolean;
52
57
  /**
53
58
  * Promise that resolve when the kernel is loaded.
54
59
  */
package/lib/kernel.js CHANGED
@@ -24,6 +24,7 @@ class BasthonEvent extends Event {
24
24
  */
25
25
  export class KernelBase {
26
26
  constructor(rootPath) {
27
+ this._ready = false;
27
28
  this._loaded = new PromiseDelegate();
28
29
  this._pageLoad = new PromiseDelegate();
29
30
  this.execution_count = 0;
@@ -111,8 +112,13 @@ export class KernelBase {
111
112
  await this.launch();
112
113
  // connecting eval to basthon.eval.request event.
113
114
  this.addEventListener("eval.request", this.evalFromEvent.bind(this));
115
+ this._ready = true;
114
116
  this._loaded.resolve();
115
117
  }
118
+ /**
119
+ * Is the kernel ready?
120
+ */
121
+ get ready() { return this._ready; }
116
122
  /**
117
123
  * Promise that resolve when the kernel is loaded.
118
124
  */
package/lib/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const VERSION = "0.36.10";
1
+ export declare const VERSION = "0.38.0";
package/lib/version.js CHANGED
@@ -1 +1 @@
1
- export const VERSION = "0.36.10";
1
+ export const VERSION = "0.38.0";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@basthon/kernel-base",
3
- "version": "0.36.10",
3
+ "version": "0.38.0",
4
4
  "description": "Basthon - Base Kernel",
5
5
  "homepage": "https://basthon.fr",
6
6
  "bugs": {
@@ -36,5 +36,5 @@
36
36
  "publishConfig": {
37
37
  "access": "public"
38
38
  },
39
- "gitHead": "107f9cca4c8e93a4c8858b298369d945866b4694"
39
+ "gitHead": "c66532cfb78ee398bd303080bce81748b0ee8fa4"
40
40
  }