Skip to content

Commit

Permalink
Fix typenames link
Browse files Browse the repository at this point in the history
  • Loading branch information
droserasprout committed Dec 9, 2021
1 parent 988e1f9 commit 9497b9d
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 16 deletions.
16 changes: 0 additions & 16 deletions cookbook/reusing-typename.md

This file was deleted.

17 changes: 17 additions & 0 deletions cookbook/reusing-typenames.md
Original file line number Diff line number Diff line change
@@ -1 +1,18 @@
# Reusing typename for different contracts

In some cases, you may want to make some manual changes in typeclasses and ensure they won't be lost on init. Let's say you want to reuse typename for multiple contracts providing the same interface (like FA1.2 and FA2 tokens) but having different storage structure. You can comment out differing fields which are not important for your index.

`types/contract_typename/storage.py`

```python
# dipdup: ignore

...

class ContractStorage(BaseModel):
some_common_big_map: Dict[str, str]
# unique_big_map_a: Dict[str, str]
# unique_big_map_b: Dict[str, str]
```

Files starting with `# dipdup: ignore` won't be overwritten on init.

0 comments on commit 9497b9d

Please sign in to comment.