nujan-io / nujan-ide

Web IDE, powered by Nujan, is your ultimate browser-based IDE designed to simplify the journey of writing, testing, compiling, deploying, and interacting with smart contracts on TON. Write smart contracts from anywhere, No setups, no downloads, just pure convenience and versatility.
https://ide.nujan.io
Other
111 stars 12 forks source link

Tact Docs integration #95

Open anton-trunov opened 3 weeks ago

anton-trunov commented 3 weeks ago

Web IDE should support getting source code from the Tact docs. For instance, runnable code snippets from the Tact docs can be presented as small contracts with getters.

cc @novusnota for further discussion and shaping this proposal

novusnota commented 3 weeks ago

Like, to add "Run this code in Nujan" kind of text/button to all (or some of) the documentation snippets on https://docs.tact-lang.org, then introduce some way of creating new contracts in Nujan via a GET (100% possible) or POST (may be possible) request and lead people via that?

anton-trunov commented 3 weeks ago

Yeah, something like that

rahulyadav-57 commented 3 weeks ago

With the new file system I'm working on, this can be easily achieved. The doc will be having a small snippet that can be inserted as a base64 code in URL. https://ide.nujan.io/?code=base64OfSnippet

Since users might click on multiple try code snippets, we can store them in an in-memory file system with an option to save them permanently. This approach will help keep the workspace/project list clean.

Later on once we have a support of git and any other cloud storage for files. We can provide an option to embed it similar to codepen. So user don't have to switch new tab.