Skip to content
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

Set up cw-storage-plus outline #20

Merged
merged 1 commit into from
Jun 4, 2024
Merged
Show file tree
Hide file tree
Changes from all 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
1 change: 1 addition & 0 deletions src/pages/_meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"index": "Welcome",
"core": "CosmWasm Core",
"sylvia": "Sylvia",
"cw-storage-plus": "cw-storage-plus",
"cw-multi-test": "MultiTest",
"how-to-doc": "How to doc",
"tags": {
Expand Down
4 changes: 4 additions & 0 deletions src/pages/cw-storage-plus.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Introduction

TODO: Describe what low-level interface `cw-storage-plus` builds on, and how it
provides typed abstractions on top of it
8 changes: 8 additions & 0 deletions src/pages/cw-storage-plus/_meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"basics": "Basics",
"containers": "Containers",
"key-collisions": "Key collisions",
"iteration": "Iteration",
"snapshots": "Snapshots",
"multi-indexes": "Multi index collections"
}
4 changes: 4 additions & 0 deletions src/pages/cw-storage-plus/basics.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Basics

TODO: Describe the way storage containers generally work, how prefixes provide a
"slice" of the whole namespace, etc
5 changes: 5 additions & 0 deletions src/pages/cw-storage-plus/containers/_meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"item": "Item",
"map": "Map",
"deque": "Deque"
}
7 changes: 7 additions & 0 deletions src/pages/cw-storage-plus/containers/deque.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# `Deque`

## Overview

## Examples

### ?
9 changes: 9 additions & 0 deletions src/pages/cw-storage-plus/containers/item.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# `Item`

## Overview

## Examples

### Saving an admin address

### Saving a config structure
7 changes: 7 additions & 0 deletions src/pages/cw-storage-plus/containers/map.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# `Map`

## Overview

## Examples

### Keeping users' balances
9 changes: 9 additions & 0 deletions src/pages/cw-storage-plus/iteration.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Iteration

TODO: how to generally take advantage of iteration

TODO: bounds, inclusive-exclusive

TODO: `Map` iteration - surprising behavior with order and bounds?

TODO: how to use `Prefix` and such
12 changes: 12 additions & 0 deletions src/pages/cw-storage-plus/key-collisions.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import { Callout } from "nextra/components";

# Key collisions

TODO: Explain how key collisions shouldn't generally happen as long as unique
prefixes are chosen

<Callout type="warning">
Warning here about a potential nefarious key collision below
</Callout>

https://confio.slack.com/archives/C06A73TKXST/p1709815517501709
3 changes: 3 additions & 0 deletions src/pages/cw-storage-plus/multi-indexes.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Multi index collections

TODO: bonus section, maybe flesh out, maybe remove
3 changes: 3 additions & 0 deletions src/pages/cw-storage-plus/snapshots.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Snapshots

TODO: bonus section, maybe flesh out, maybe remove