purescript-signal icon indicating copy to clipboard operation
purescript-signal copied to clipboard

window is not defined

Open the-man-with-a-golden-mind opened this issue 3 years ago • 1 comments

When I am trying to use purescript-signal then on 'spago run' I am getting error: "ReferenceError: window is not defined" on line: https://github.com/bodil/purescript-signal/blob/0276f5b0c25993420e1707710f1a530e9cfee625/src/Signal/DOM.js#L108

Hello,

thank you for your report.

Just to be sure: Do you use the windowDimensions effect?

Because this part of the library (Signal.DOM) is intended to work when using purescript-signal from a browser-context and as node will not have a window this is to be expected.

But if you aren't using anything from Signal.DOM this is probably a bug and we should look into it.

Can you give us some more detail on your program or maybe even a short example of an program that exhibits this error?

CarstenKoenig avatar Oct 16 '21 12:10 CarstenKoenig