LivelyKernel / lively4-core

A Self-supporting, Web-based Development Environment
https://lively-kernel.org/lively4/lively4-core/start.html
MIT License
73 stars 25 forks source link

AE: Array method in AE freezes lively #412

Open Markus-Brand opened 3 years ago

Markus-Brand commented 3 years ago

import _ from 'src/external/lodash/lodash.js';
const options = [1, 2, 3];

aexpr(() => {
  let x = 0;
  options.forEach(y => x+=y);
  lively.notify("x: " + x);
  return x;
}).onChange(lively.notify);

options[0]++;
options.values()

Creating the hook triggers the AE Evaluation, which creates a hook and so on