Skip to content
This repository has been archived by the owner on Feb 1, 2024. It is now read-only.

Implement versioning for ink! playground #460

Open
1 of 7 tasks
achimcc opened this issue Nov 8, 2022 · 0 comments
Open
1 of 7 tasks

Implement versioning for ink! playground #460

achimcc opened this issue Nov 8, 2022 · 0 comments
Labels
Docker Issue requires Docker skills enhancement New feature or request priority-high Rust Issue requires Rust coding TypeScript Issue requires TypeScript/React coding

Comments

@achimcc
Copy link
Contributor

achimcc commented Nov 8, 2022

Currently, ink! Playground can interpret and compile only one specific version of ink!. To make the playground useful for tutorials and also to share code snippets in forums, we need to encode the ink! Version as part of the URL of the playground.

Gives a high-level overview on how to implement feature request #427

  • Serve all usages of Cargo.toml and lib.rs of the sample ink! flipper contract by the reference contract in the crates folder. Replace the contract crate by a (sub-) crate which contains sample flipper contracts for all versions of ink!
  • Support compilation of multiple ink! versions. Two ways here to go: build multiple docker images with compilation cache for each ink! version or mount an external volume into the sysbox runtime which holds the shared compilation cache and which is populated in advance.
  • Allow the specification of the referenced ink! version as part of the URL, we should save this version in some React context state variable
  • Allow to manually specifiy the ink! version in the Frontend under settings.
  • The actix web backend url should receive the ink! version as part of a compilation request and should call the according docker command.
  • Build the serialized .json dependencies for each version of ink! to be used in Rust Analyzer
  • The frontend/Rust Analyzer should only lazy load the required serialized json ink! dependencies from the backend and feed them into Rust Analyzer
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Docker Issue requires Docker skills enhancement New feature or request priority-high Rust Issue requires Rust coding TypeScript Issue requires TypeScript/React coding
Projects
None yet
Development

No branches or pull requests

1 participant