Skip to content

Commit

Permalink
Merge pull request #33 from map3xyz/adding-config
Browse files Browse the repository at this point in the history
adding config to Chain Objects
  • Loading branch information
pellicceama authored Nov 2, 2022
2 parents ed92900 + cac54ce commit e8d4208
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 2 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ exec/
/tmp/**/
tmp.csv
tmp
.yarn/install-state.gz

# Logs
logs
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@map3xyz/assets-helper",
"version": "1.0.159",
"version": "1.0.160",
"description": "A library for maintaining the assets repo.",
"author": "pellicceama",
"keywords": [
Expand Down
3 changes: 2 additions & 1 deletion src/model/ChainObject.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { sortObjectKeys } from "../utils";
import { Logos } from "./Logos";
import { RepoObject } from "./RepoObject";
import { TagName } from "./Tag";
import { Description, Links } from "./types";
import { Config, Description, Links } from "./types";
import { getUUID } from "./UUID";

export type ObjectType = 'network' | 'asset';
Expand All @@ -12,6 +12,7 @@ export abstract class ChainObject extends RepoObject {
networkCode: string;
active: boolean;
color: string | null;
config: Config | null;
decimals: number;
description: Description | null;// foreign keys
links: Links | null; // foreign keys
Expand Down
5 changes: 5 additions & 0 deletions src/model/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,8 @@ export interface Links {
whitepaper?: string;
}


type ConfigValue = string | number | boolean;
export interface Config {
[key: string]: ConfigValue;
}

0 comments on commit e8d4208

Please sign in to comment.