diff --git a/packages/dapp/src/util/consts.ts b/packages/dapp/src/util/consts.ts index fc409ea..cc75077 100644 --- a/packages/dapp/src/util/consts.ts +++ b/packages/dapp/src/util/consts.ts @@ -1,9 +1,8 @@ const SNAP_VERSION = '>=0.1.14'; const LOCAL_SNAP_ID = 'local:http://localhost:8080'; -// const NPM_SNAP_ID = 'npm:@polkagate/snap'; - -export const DEFAULT_SNAP_ORIGIN = LOCAL_SNAP_ID; +const NPM_SNAP_ID = 'npm:@polkagate/snap'; +export const DEFAULT_SNAP_ORIGIN = process.env.POLKAGATE_NODE_ENV === 'development' ? LOCAL_SNAP_ID : NPM_SNAP_ID; export const SUPPORTED_SNAPS = { [DEFAULT_SNAP_ORIGIN]: { version: SNAP_VERSION }, };