aboutsummaryrefslogtreecommitdiffstats
path: root/packages
diff options
context:
space:
mode:
authorFabio Berger <me@fabioberger.com>2018-08-23 21:53:32 +0800
committerFabio Berger <me@fabioberger.com>2018-08-23 21:53:32 +0800
commit29a9e1fc4ec6bc902dc8e76a4af712f2dff4ffb6 (patch)
treec685738095ec4a9d3cfb700e54b3527438a968e7 /packages
parentae937cfcce0e751bc931a8f05df0b67b62962023 (diff)
downloaddexon-0x-contracts-29a9e1fc4ec6bc902dc8e76a4af712f2dff4ffb6.tar
dexon-0x-contracts-29a9e1fc4ec6bc902dc8e76a4af712f2dff4ffb6.tar.gz
dexon-0x-contracts-29a9e1fc4ec6bc902dc8e76a4af712f2dff4ffb6.tar.bz2
dexon-0x-contracts-29a9e1fc4ec6bc902dc8e76a4af712f2dff4ffb6.tar.lz
dexon-0x-contracts-29a9e1fc4ec6bc902dc8e76a4af712f2dff4ffb6.tar.xz
dexon-0x-contracts-29a9e1fc4ec6bc902dc8e76a4af712f2dff4ffb6.tar.zst
dexon-0x-contracts-29a9e1fc4ec6bc902dc8e76a4af712f2dff4ffb6.zip
Look for all TS mapped types
Diffstat (limited to 'packages')
-rw-r--r--packages/monorepo-scripts/src/utils/doc_generate_and_upload_utils.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/monorepo-scripts/src/utils/doc_generate_and_upload_utils.ts b/packages/monorepo-scripts/src/utils/doc_generate_and_upload_utils.ts
index 0768b14b5..de52b3a47 100644
--- a/packages/monorepo-scripts/src/utils/doc_generate_and_upload_utils.ts
+++ b/packages/monorepo-scripts/src/utils/doc_generate_and_upload_utils.ts
@@ -56,12 +56,12 @@ export class DocGenerateAndUploadUtils {
// Some nodes of type reference are for subtypes, which we don't want to return.
// We therefore filter them out.
const SUB_TYPE_PROPERTY_NAMES = ['inheritedFrom', 'overwrites', 'extendedTypes', 'implementationOf'];
+ const TS_MAPPED_TYPES = ['Partial', 'Promise', 'Readonly', 'Pick', 'Record'];
if (
!_.isUndefined(node.type) &&
_.isString(node.type) &&
node.type === 'reference' &&
- node.name !== 'Partial' &&
- node.name !== 'Promise' &&
+ !_.includes(TS_MAPPED_TYPES, node.name) &&
!_.includes(SUB_TYPE_PROPERTY_NAMES, propertyName)
) {
updatedReferenceNames = _.uniq([...referenceNames, node.name]);