[phpBB Debug] PHP Warning: in file [ROOT]/ext/kinerity/bestanswer/event/main_listener.php on line 514: Undefined array key "poster_answers"
openhabforum.de • [GELÖST] OH 2.5.5. Transformation JS - Welche ECMAStript Version wird unterstützt?
Seite 1 von 1

[GELÖST] OH 2.5.5. Transformation JS - Welche ECMAStript Version wird unterstützt?

Verfasst: 25. Jun 2020 17:42
von thomas_w
Problem:
Ich habe versucht folgende JS Transformation zu nutzen, leider ohne Erfolg.

Ein Beispiel ohne tieferen Sinn:
import name from "modulname";

(function(i) {
var array = i.split(" ");
return array[array.length - 1].length;
})(input)
https://developer.mozilla.org/de/docs/W ... nts/import

import scheint nicht zu funktionieren. Ich finde auch kein Beispiel im OpenHAB Forum.

Frage:
Welche ECMAScriptversion wird von OpenHAB 2.5.5 innerhalb JS Transformation unterstützt? Sollte Import funktionieren? Wenn ja, wie?

Danke und Grüße
Thomas

Re: OH 2.5.5. Transformation JS - Welche ECMAStript Version wird unterstützt?

Verfasst: 30. Jun 2020 10:08
von J-N-K
5, mehr ist mit Nashorn und Java8 nicht drin.