Browse Source

types: add explicit dependency on moment

Mokhtar Naamani 4 years ago
parent
commit
3c2414f4bb
2 changed files with 3 additions and 1 deletions
  1. 2 1
      types/package.json
  2. 1 0
      types/src/common.ts

+ 2 - 1
types/package.json

@@ -16,7 +16,8 @@
     "@types/lodash": "^4.14.157",
     "@types/vfile": "^4.0.0",
     "ajv": "^6.11.0",
-    "lodash": "^4.17.15"
+    "lodash": "^4.17.15",
+    "moment": "^2.24.0"
   },
   "devDependencies": {
     "typescript": "^3.7.2"

+ 1 - 0
types/src/common.ts

@@ -1,6 +1,7 @@
 import { Struct, Option, Text, bool, Vec, u16, u32, u64, getTypeRegistry } from "@polkadot/types";
 import { BlockNumber, Moment } from '@polkadot/types/interfaces';
 import { Codec } from "@polkadot/types/types";
+// we get 'moment' because it is a dependency of @polkadot/util, via @polkadot/keyring
 import moment from 'moment';
 import { JoyStruct } from './JoyStruct';
 export { JoyStruct } from './JoyStruct';