Skip to content

Commit

Permalink
Merge branch 'V4' of github.com:WalletConnect/web3modal into V4
Browse files Browse the repository at this point in the history
  • Loading branch information
svenvoskamp committed Feb 7, 2024
2 parents 35af556 + 49ff5d1 commit cc5a7e4
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
5 changes: 2 additions & 3 deletions dangerfile.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/* eslint-disable no-await-in-loop */
import { danger, fail, message, warn } from 'danger'
import corePackageJson from './packages/core/package.json' assert { type: 'json' }
import { ConstantsUtil } from './packages/scaffold-utils/src/ConstantsUtil'
import coreScaffoldUtilsJson from './packages/scaffold-utils/package.json' assert { type: 'json' }

// -- Constants ---------------------------------------------------------------
const TYPE_COMMENT = `// -- Types --------------------------------------------- //`
Expand All @@ -10,7 +10,6 @@ const CONTROLLER_COMMENT = `// -- Controller -----------------------------------
const RENDER_COMMENT = `// -- Render -------------------------------------------- //`
const STATE_PROPERTIES_COMMENT = `// -- State & Properties -------------------------------- //`
const PRIVATE_COMMENT = `// -- Private ------------------------------------------- //`
const PACKAGE_VERSION = ConstantsUtil.VERSION

// -- Data --------------------------------------------------------------------
const { modified_files, created_files, deleted_files, diffForFile } = danger.git
Expand Down Expand Up @@ -268,7 +267,7 @@ checkClientPackages()

// -- Check sdkVersion ------------------------------------------------------------
function checkSdkVersion() {
if (PACKAGE_VERSION !== corePackageJson.version) {
if (coreScaffoldUtilsJson.version !== corePackageJson.version) {
fail(`VERSION in utils/constants does't match core package.json version`)
}
}
Expand Down
4 changes: 3 additions & 1 deletion packages/scaffold-utils/src/ConstantsUtil.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import scaffoldUtilsPackageJson from '../package.json' assert { type: 'json' }

export const ConstantsUtil = {
WALLET_CONNECT_CONNECTOR_ID: 'walletConnect',
INJECTED_CONNECTOR_ID: 'injected',
Expand All @@ -11,5 +13,5 @@ export const ConstantsUtil = {
ADD_CHAIN_METHOD: 'wallet_addEthereumChain',
EIP6963_ANNOUNCE_EVENT: 'eip6963:announceProvider',
EIP6963_REQUEST_EVENT: 'eip6963:requestProvider',
VERSION: '4.0.0'
VERSION: scaffoldUtilsPackageJson.version
}
2 changes: 1 addition & 1 deletion packages/scaffold-utils/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@
"declarationDir": "./dist/types"
},
"extends": "../../tsconfig.json",
"include": ["exports", "src"]
"include": ["exports", "src", "package.json"]
}

0 comments on commit cc5a7e4

Please sign in to comment.