Skip to content

Updated app-template docs #304

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Apr 22, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions framework/docs/src/4_get_started/2_installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ The template contains a scaffold contract that you can use as a starting point f

If there's anything you don't understand about the template please don't hesitate to reach out to us on our <a href="https://discord.com/invite/uch3Tq3aym" target="_blank">Discord</a> server.

## Front-end layout
<!-- ## Front-end layout

To generate the front-end scaffold, you can run `just ts-codegen`, which will run a code generation script for you found in the `typescript/scripts` folder. The code generation script will generate TypeScript code based on the specifications defined in the contract schemas.

Expand All @@ -93,7 +93,7 @@ follows:
- `Template.message-composer.ts`: Aids in crafting messages necessary for interacting with a specific
blockchain contract, particularly for updating configurations. It contains a class that generates message objects that can be sent to the blockchain for execution.
- `Template.msg-builder.ts`: Provides static methods on abstract classes to create message objects for querying or executing actions on the blockchain. It essentially facilitates the building of structured messages for blockchain interactions.
- `Template.types.ts`: Defines various data structures and types that represent the structure of messages and responses within the blockchain module, aiding in maintaining consistency across different operations in the module.
- `Template.types.ts`: Defines various data structures and types that represent the structure of messages and responses within the blockchain module, aiding in maintaining consistency across different operations in the module. -->

## Tools used in the template

Expand Down
19 changes: 14 additions & 5 deletions framework/docs/src/4_get_started/7_module_deployment.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ network.

### Compiling your module

Once you have confirmed that your module works as expected you can spin up a local node and deploy Abstract + your app onto the chain. You need [Docker](https://www.docker.com/) installed for this step.

You can compile your module by running the following command:

```bash
Expand All @@ -25,17 +27,24 @@ $ just wasm
> it from <a href="https://docs.docker.com/get-docker/" target="_blank">here</a>.

This should result in an `artifacts` directory being created in your project root. Inside you will find
a `my_module.wasm` file that is your module's binary.
a `my_module.wasm` file that is your module's binary.

```admonish warning
Make sure it's the same name as mentioned in `Cargo.toml` file. If not, just edit it to match.
```

### Publish your module

Before attempting to publish your app you need to add your mnemonic to the `.env` file. **Don't use a mnemonic that has mainnet funds for this.** Make sure this account has funds. If you don't have the deployment will fail. Get funds from respective chain faucets or ask for some test tokens on Abstract Discord.

Now you can go ahead and deploy the module to the network(s) you want to make it available on. You can do this by
running the following command:
Now you can go ahead and publish the module to the network(s) you want to make it available on. You can do this by running the following command:

```bash
$ just deploy uni-1
$ just publish uni-6
> Deploying module...
```

This will use the module's `examples/deploy.rs` script to deploy the module to the `uni-1` network. The resulting
This will use the module's `examples/publish.rs` script to deploy the module to the `uni-1` network. The resulting
code-id of your contract should now be in the `state.json` file created for you. The script will also attempt to
register the module on the Abstract Version Control, hence the mnemonic used in the script should be the same as the one
you used to create the account and register the namespace.
Expand Down