pyscript / pyscript

PyScript is an open source platform for Python in the browser. Try PyScript: https://pyscript.com Examples: https://tinyurl.com/pyscript-examples Community: https://discord.gg/HxvBtukrg2
https://pyscript.net/
Apache License 2.0
18.02k stars 1.44k forks source link

Add example of pyscript using TiddlyWIki #409

Open AnthonyMuscio opened 2 years ago

AnthonyMuscio commented 2 years ago

Is your feature request related to a problem? Please describe. I do not know pyscript even python, but I am a TiddlyWiki Enthusiast which allows us to build a app inside a single HTML file. One member has used an in browser version of the Basic Programming language and is building documentation, examples and program exchange tools all in the browser - or TiddlyWikis single html file implementation.

Describe the solution you'd like I Expect nothing but I think it may suit your community to look at implementing pyscript in a custom edition of TiddlyWiki in a virtuosic circle.

Describe alternatives you've considered Not applicable

Additional context Contact me by message in the TiddlyWIki Discourse to chat more https://talk.tiddlywiki.org/u/TW_Tones

Shahin-rmz commented 2 years ago

Nice feature request though, A question. Can we have tiddly wiki selfhosted or sync the files by ourselves (and not dropbox)?

AnthonyMuscio commented 2 years ago

TiddlyWikis can be either single file, local file, hosted or served with little or no changes.

A lot of the plugins to extend features include open source javascript libraries or CSS frameworks. I believe TiddlyWiki is an ideal platform to promote open source projects as people can make use of a working environment "out of the Box" along with SDK, Documentation and personal notes. It also allows the interchange of code examples and snipits to help with community support.

The Basic anywhere by a user can be found here, https://basicanywheremachine.neocities.org/BAM_IDE.html it is slow to load and he has not yet installed a splash screen while loading but there you can see Basic running in the browser, in a highly customised wiki. The speed issues in this demo can be fixed.

nmstoker commented 2 years ago

Interesting idea, but isn't this something to implement on the TiddlyWiki side?

marimeireles commented 2 years ago

This is a very cool project :) I can see how it has a good synergy with pyscript. Thanks for letting us know. I'll add an example tag so we can think of it when we're developing our community pages =)

WebReflection commented 2 months ago

a "tad" late to the party but I don't understand what we can do here to move this request any way forward.

Interesting idea, but isn't this something to implement on the TiddlyWiki side?

agreed ... my counter-question would be: what is stopping TiddlyWiki from embedding our style and script and show a terminal, an editor, or anything Python related? 🤔

I am just trying to understand if I should keep this bug open, and define some "call for action", or close it as irrelevant for PyScript project itself and just rotting in the list of opened issues.

Thanks in advance for any sort of feedback or extra clarification around how we can proceed doing ... well, something.

ramalho commented 2 weeks ago

Hello, the request is in the title of the issue: "Add example of pyscript using TiddlyWIki"

@AnthonyMuscio, @marimeireles, and I are intrigued by the idea of having an example showing how to embed PyScript in a TiddlyWiki page. This sounds very cool to me: "people can make use of a working environment 'out of the Box' along with SDK, Documentation and personal notes".

Perhaps this is not the repo for that issue, since it is request for an example. Is there a place where people can post ideas for new examples, even if they are unable to implement them?

I believe 100% that great examples are one key to the success of any programming environment, particularly one for beginners.

nmstoker commented 2 weeks ago

Hello @ramalho ,

the request is in the title of the issue: "Add example of pyscript using TiddlyWIki"

There's no need to remind people of that, nothing in this discussion suggests anyone involved here has missed this obvious point. 🙂

I'm delighted you and the others are intrigued, but you collectively have so far failed to demonstrate why the onus here is on the thing being embedded or the thing in which something is being embedded.

My position is that it's for TiddyWiki to handle this. Maybe if the people on the TiddyWiki side did the work to show how it's done then perhaps the people who own pyscript documentation might be happy to include it / link to it. Essentially people need to go beyond being intrigued and actually do some of the running here! But I should be clear I am in no way representing pyscript here, I'm just pointing out the illogical nature of this request as originally stated.

Perhaps this is not the repo for that issue

🎯 The thing that would do the embedding here is TiddyWiki so it seems like this should be raised here:

https://github.com/TiddlyWiki/TiddlyWiki5/issues

There seems to be no reference to Pyscript there so far.

Who knows, perhaps TiddyWiki might be motivated by comments such as this: I believe 100% that great examples are one key to the success of any programming environment,

All the best with this! It may well be cool if someone can pull this off.

AnthonyMuscio commented 2 weeks ago

Just to clarify this original issue suggests the value of using tiddlywiki as a platform to present your suit of tools and use them in an app, website or to create what would be a software development kit/platform. Integration with tiddlywiki may assist pyscript to be used to build full solutions, or collaborations.

Unless you know tiddlywiki or learn it, you may find collaboration the best way to start.

If your community can bring someone with expertise on integrating pyscript into html the tiddlywiki community can bring someone with expertise on integrating other solutions into tiddlywiki we can proceed, I may be this person for tiddlywiki.

I am confident that many projects similar to your own may be quite easy to integrate as they all use global standards like CSS, html, JavaScript. This will benefit your project and tiddlywiki. A virtuous circle.

ramalho commented 2 weeks ago

@nmstoker, given that PyScript is embedded in a browser, then we should close this issue tracker and use Bugzilla instead. 😉

I think a better plan is to clarify to users where is the place to post suggestions for PyScript examples, if this is not the place for that.

That's the only reason why I started my comment recalling the title of the issue.

I believe 100% that everyone here is trying their best to contribute to PyScript.

WebReflection commented 2 weeks ago

@AnthonyMuscio to be honest, PyScript is a <script type="py"> or a <script type="mpy"> away from being usable on any page, as long as its core module has been included. It takes nothing to have it embedded in any project or PL that produces HTML which is why I am still a bit puzzled around "how can we help there?" 🤔

If it's about having an editor we have the py-editor type, if it's about having a worker that can run code from scratch or keep running, we have a donkey export ... if we had any basic example/use case that shows expectations that are not currently met, we can work around it and provide an example that actually fulfills those expectations.

I hope this comment makes somehow sense.