Announcing Motoko Playground!

We are excited to announce Motoko Playground: https://m7sm4-2iaaa-aaaab-qabra-cai.raw.ic0.app/

The Motoko playground allows users to build and deploy Motoko canisters directly in the browser,
without downloading SDK, setting up a local dev environment, and without a wallet.

The code is also open sourced at GitHub - dfinity/motoko-playground: Motoko playground

We plan on adding many more features to make playground a full-featured web IDE for the Internet Computer. Community contributions are highly welcomed!

26 Likes

Very impressive stuff!

3 Likes

Thanks for the tool it’s really helpful.
I have a question, how can one add new file?

Congrats :clap:

Would there be a Rust version of that playground?

Great, thanks!
Looking forward to deploying Playground to the test network and interacting with other apps!

1 Like

Really cool! I tried it and it is really smooth!

1 Like

I have a question, how can one add new file?

Not yet, we have an issue for this. For now, you can import files from github

Would there be a Rust version of that playground?

Rust works very differently from Motoko, so it will probably be a whole new project. But we can easily support users to upload arbitrary Wasm modules, so that you can compile Rust code locally and upload.

4 Likes

We add a “Save & Share” button so that you can save your work in the Motoko Playground to our backend canister. It’s also useful for people asking Motoko questions in the forum, where they can share the playground links instead of pasting code snippets.

4 Likes

In regards to the full-featured web IDE, has anyone had a look at VS Code in the browser? I understand that the core editor itself is monaco but I wonder if we can integrate into a well established, web based, full featured, open source IDE. It seems the [GitHub Project Selection], [Save & Share], [Deploy] and other features could be integrated into a fork of that project. Another feature could include a “simplified”, beginner friendly mode. It would look similar to the current project but can also switch to a “normal” mode, which would just be the full featured browser-based Visual Studio Code IDE.

Any thoughts?

I think that, plus a nice Github Action integration could be a totally viable workflow

1 Like

Could be. But that means we need to host the IDE on a cloud VM instead of IC. The IC can only run WebAssembly, not docker images. Our focus is to provide features that are unique to the IC, such as deployment, canister interaction, cycles, while adding some convenience features, such as code sharing, when resource permitting. The community is free to port the code to any platforms they like.

3 Likes

I see. Thank you for the clarity, moving to a cloud VM seems counter productive.

We just add canister profiling in Motoko playground. You can now count the number of Wasm instructions executed for each update call, including the number of instructions spent in garbage collection. Thanks to our recent improvements in GC, the GC cost is significantly reduced!

3 Likes

is there any test network?

Yes!!!

the stupid forum often failed when pasting code:
https://forum.dfinity.org/t/i-cant-reply-some-topics-somtimes/4082

I’m not found any network, Looking forward to future