Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

node REPL is not working after let win = new Window(800, 600) #148

Open
rkompass opened this issue Aug 25, 2023 · 4 comments
Open

node REPL is not working after let win = new Window(800, 600) #148

rkompass opened this issue Aug 25, 2023 · 4 comments

Comments

@rkompass
Copy link

The title says it basically.

I'm a beginner with node. I installed skia-canvas to have a way to explore drawing on a canvas/window outside a browser.
I use Manjaro Linux, installed with npm install skia-canvas

After starting node in a terminal I typed:

const {Window} = require('skia-canvas')
let win = new Window(800, 600)

after that I can see my typing no longer...., seems the node REPL is gone.

Any help is appreciated.

@rkompass
Copy link
Author

I saved the third example in the Readme.md that described drawing on a window in a file and started it with node.
That worked, so I conclude that skia-canvas is working.

Do I need some kind of asynchronous setup (and an async REPL) to achieve interactivity?
Help on this is welcome, thank you.

@kugimiya
Copy link

Seems like setTimeout stop working too. It starts to work only when skia-canvas window close called.

@samizdatco
Copy link
Owner

For more detail about the event-loop behavior you're describing, take a look at the Window docs: Responding to Events.

@kugimiya
Copy link

For more detail about the event-loop behavior you're describing, take a look at the Window docs: Responding to Events.

ok, ty

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants