From ce6d9424e616c0d94ff04c3a533501a8865f4c54 Mon Sep 17 00:00:00 2001 From: Jaco Greeff Date: Mon, 9 Nov 2020 17:40:52 +0100 Subject: [PATCH] Build esnext modules (#2831) --- babel.esnext.js | 4 ++++ package.json | 2 +- packages/api-contract/package.json | 2 ++ packages/api-derive/package.json | 2 ++ packages/api/package.json | 2 ++ packages/metadata/package.json | 2 ++ packages/rpc-core/package.json | 2 ++ packages/rpc-provider/package.json | 2 ++ packages/typegen/package.json | 2 ++ packages/types-known/package.json | 2 ++ packages/types/package.json | 2 ++ yarn.lock | 10 +++++----- 12 files changed, 28 insertions(+), 6 deletions(-) create mode 100644 babel.esnext.js diff --git a/babel.esnext.js b/babel.esnext.js new file mode 100644 index 0000000000..be471bb4b7 --- /dev/null +++ b/babel.esnext.js @@ -0,0 +1,4 @@ +// Copyright 2017-2020 @polkadot/api authors & contributors +// SPDX-License-Identifier: Apache-2.0 + +module.exports = require('@polkadot/dev/config/babel.esnext.js'); diff --git a/package.json b/package.json index 078cb31731..12f2485fd2 100644 --- a/package.json +++ b/package.json @@ -26,7 +26,7 @@ "@babel/core": "^7.12.3", "@babel/register": "^7.12.1", "@babel/runtime": "^7.12.1", - "@polkadot/dev": "^0.59.20", + "@polkadot/dev": "^0.59.21", "@polkadot/ts": "^0.3.53", "@polkadot/typegen": "workspace:packages/typegen", "@types/jest": "^26.0.15", diff --git a/packages/api-contract/package.json b/packages/api-contract/package.json index 2f49f52fe2..c5ee88542b 100644 --- a/packages/api-contract/package.json +++ b/packages/api-contract/package.json @@ -3,6 +3,8 @@ "version": "2.6.1", "description": "Interfaces for interacting with contracts and contract ABIs", "main": "index.js", + "module": "esnext/index.js", + "sideEffects": false, "keywords": [ "Polkadot", "ABI" diff --git a/packages/api-derive/package.json b/packages/api-derive/package.json index e1a77d06ca..e36a5f1507 100644 --- a/packages/api-derive/package.json +++ b/packages/api-derive/package.json @@ -3,6 +3,8 @@ "version": "2.6.1", "description": "Common functions used across Polkadot, derived from RPC calls and storage queries.", "main": "index.js", + "module": "esnext/index.js", + "sideEffects": false, "keywords": [ "Polkadot", "Promise", diff --git a/packages/api/package.json b/packages/api/package.json index bb9740b79a..d49968fa1a 100644 --- a/packages/api/package.json +++ b/packages/api/package.json @@ -3,6 +3,8 @@ "version": "2.6.1", "description": "Promise and RxJS wrappers around the Polkadot JS RPC", "main": "index.js", + "module": "esnext/index.js", + "sideEffects": false, "keywords": [ "Polkadot", "RxJs" diff --git a/packages/metadata/package.json b/packages/metadata/package.json index 4e3473d03b..ff68cff990 100644 --- a/packages/metadata/package.json +++ b/packages/metadata/package.json @@ -3,6 +3,8 @@ "version": "2.6.1", "description": "Helpers to extract information from runtime metadata", "main": "index.js", + "module": "esnext/index.js", + "sideEffects": false, "publishConfig": { "access": "public", "registry": "https://registry.npmjs.org" diff --git a/packages/rpc-core/package.json b/packages/rpc-core/package.json index f34444f167..8122535a79 100644 --- a/packages/rpc-core/package.json +++ b/packages/rpc-core/package.json @@ -3,6 +3,8 @@ "version": "2.6.1", "description": "A JavaScript wrapper for the Polkadot JsonRPC interface", "main": "index.js", + "module": "esnext/index.js", + "sideEffects": false, "keywords": [ "Polkadot", "JsonRPC" diff --git a/packages/rpc-provider/package.json b/packages/rpc-provider/package.json index f17ae528d4..22b90512d7 100644 --- a/packages/rpc-provider/package.json +++ b/packages/rpc-provider/package.json @@ -3,6 +3,8 @@ "version": "2.6.1", "description": "Transport providers for the API", "main": "index.js", + "module": "esnext/index.js", + "sideEffects": false, "keywords": [ "Polkadot", "JsonRPC" diff --git a/packages/typegen/package.json b/packages/typegen/package.json index b716292bb6..2e6fe2218b 100644 --- a/packages/typegen/package.json +++ b/packages/typegen/package.json @@ -3,6 +3,8 @@ "version": "2.6.1", "description": "Type generation scripts", "main": "index.js", + "module": "esnext/index.js", + "sideEffects": false, "bin": { "polkadot-types-chain-info": "./scripts/polkadot-types-chain-info.js", "polkadot-types-from-chain": "./scripts/polkadot-types-from-chain.js", diff --git a/packages/types-known/package.json b/packages/types-known/package.json index bb158c2aae..95317f76b3 100644 --- a/packages/types-known/package.json +++ b/packages/types-known/package.json @@ -3,6 +3,8 @@ "version": "2.6.1", "description": "A JavaScript wrapper for the Polkadot JsonRPC interface", "main": "index.js", + "module": "esnext/index.js", + "sideEffects": false, "keywords": [ "Polkadot", "JsonRPC" diff --git a/packages/types/package.json b/packages/types/package.json index 1e8899921a..62af1e804d 100644 --- a/packages/types/package.json +++ b/packages/types/package.json @@ -3,6 +3,8 @@ "version": "2.6.1", "description": "Implementation of the Parity codec", "main": "index.js", + "module": "esnext/index.js", + "sideEffects": false, "keywords": [ "Polkadot", "JsonRPC" diff --git a/yarn.lock b/yarn.lock index d53ea6bd1e..58a5133b36 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1797,9 +1797,9 @@ __metadata: languageName: unknown linkType: soft -"@polkadot/dev@npm:^0.59.20": - version: 0.59.20 - resolution: "@polkadot/dev@npm:0.59.20" +"@polkadot/dev@npm:^0.59.21": + version: 0.59.21 + resolution: "@polkadot/dev@npm:0.59.21" dependencies: "@babel/cli": ^7.12.1 "@babel/core": ^7.12.3 @@ -1885,7 +1885,7 @@ __metadata: polkadot-exec-typedoc: scripts/polkadot-exec-typedoc.js polkadot-exec-vuepress: scripts/polkadot-exec-vuepress.js polkadot-exec-webpack: scripts/polkadot-exec-webpack.js - checksum: 4d589615cc8bc2d1b302113d734e4f0a22ae8fb86f202648cb4b4a3780022fd7dab1d04ce85c5e8040849878c0372fbf19578ed6cf5cf95589054bda475fbc9b + checksum: c853d9077c256e68074fc2c08ff8e7e140f01e547e71a8021c71373c3b0fedf7a0e013e9e91eef463f3be60031ca5a1e5c7b490740d5eba5cc5e96b337369a2f languageName: node linkType: hard @@ -9397,7 +9397,7 @@ fsevents@^1.2.7: "@babel/core": ^7.12.3 "@babel/register": ^7.12.1 "@babel/runtime": ^7.12.1 - "@polkadot/dev": ^0.59.20 + "@polkadot/dev": ^0.59.21 "@polkadot/ts": ^0.3.53 "@polkadot/typegen": "workspace:packages/typegen" "@types/jest": ^26.0.15