@luxalgo/vela-pinets 0.2.4 → 0.2.5

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/README.md CHANGED
@@ -26,6 +26,15 @@ plot(ta.ema(close, 20), color=color.orange)`);
26
26
  bytes. The worker avoids a second *pinets* by inlining its own at build time.
27
27
  - **`PineWorkerEngine`** — the same Pine semantics in a Web Worker (source inlined at
28
28
  build time, spawned from a Blob URL): heavy scripts never block the chart.
29
+ - **Declaration props** — both engines publish the mutable `indicator()` / `strategy()`
30
+ declaration arguments (`initial_capital`, `precision`, …) as a props schema: Vela shows
31
+ them on the settings dialog's **Properties** tab, and hosts override them via
32
+ `addIndicator({ props })` / `handle.setProps()`. The optional `defaultProps` engine
33
+ option (`new PineEngine({ defaultProps: { initial_capital: 50000 } })`) sets host-level
34
+ defaults for scripts that don't declare the prop themselves, and `props` gates which
35
+ scripts publish the schema — `'all' | 'strategy' | 'none'`, or a whitelist of prop
36
+ keys published in the list's order (`'strategy'` gives strategies a Properties tab
37
+ while plain indicators keep an inputs-only dialog).
29
38
  - **Browser builds** — `vela-pinets.global.js` / `.global.min.js` expose
30
39
  `window.VelaPinets` for script-tag usage; load `vela.global.js` first.
31
40