paulshen's comments

paulshen | 3 years ago | on: Show HN: A Spatial Environment for Python

Thanks! I'm curious why you want to install it. All the Python runs in your browser and never leaves it. Do you want to use it offline? Or is it a matter of trust? (I understand!)

paulshen | 3 years ago | on: Show HN: A Spatial Environment for Python

Hi all! I've been working on natto.dev, a spatial environment for JavaScript. With all the buzz around PyScript, I found Pyodide and got it working inside natto! It's a beautiful piece of software.

This is a tech demo of what a Python spatial notebook could look like. It's a stripped down version of natto (eg interactive outputs, multiplayer) so please check that out if this interests you!

paulshen | 4 years ago | on: Egui: An easy-to-use immediate mode GUI

Here's the main file of the tictactoe implementation.

https://gist.github.com/paulshen/b04db68c754f73e693cd29a481c...

`update` is similar to React's render function except here it's being called on every interaction (eg mousemove tick) and redrawing the entire screen from scratch! The code runs so fast that this is fine from a perf standpoint. Note that egui has a reactive or continuous mode. You can rerender everything from scratch 60fps (continuous mode) and it'd be fine in most cases.

paulshen | 5 years ago | on: Natto.dev – A Canvas for JavaScript

Thanks! I'm using plain React. I have a React onMouseDown React listener that attaches mousemove/mouseup listeners on the window. I round the numbers to the grid.

I've seen https://reactflow.dev/ but haven't used it myself. The core drag interaction is not much code but feel free to reach out on twitter. happy to share more!

page 1