Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 0 additions & 27 deletions next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,33 +4,6 @@ const nextConfig = {
experimental: {
esmExternals: "loose",
},
transpilePackages: [
"@near-wallet-selector/core",
"@near-wallet-selector/bitget-wallet",
"@near-wallet-selector/bitte-wallet",
"@near-wallet-selector/coin98-wallet",
"@near-wallet-selector/ethereum-wallets",
"@near-wallet-selector/here-wallet",
"@near-wallet-selector/hot-wallet",
"@near-wallet-selector/intear-wallet",
"@near-wallet-selector/ledger",
"@near-wallet-selector/math-wallet",
"@near-wallet-selector/meteor-wallet",
"@near-wallet-selector/mintbase-wallet",
"@near-wallet-selector/my-near-wallet",
"@near-wallet-selector/nightly",
"@near-wallet-selector/ramper-wallet",
"@near-wallet-selector/sender",
"@near-wallet-selector/unity-wallet",
"@near-wallet-selector/welldone-wallet",
"@near-wallet-selector/wallet-connect",
"@near-wallet-selector/xdefi",
"@meteorwallet/sdk",
"nanoid",
"@walletconnect/modal",
"@walletconnect/modal-ui",
],

async redirects() {
return [
{
Expand Down
33 changes: 7 additions & 26 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,32 +27,8 @@
"@ebay/nice-modal-react": "^1.2.13",
"@formkit/tempo": "^0.1.2",
"@hookform/resolvers": "^3.9.1",
"@hot-labs/near-connect": "^0.8.2",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Check npm registry info for `@hot-labs/near-connect`
curl -s https://registry.npmjs.org/@hot-labs/near-connect | jq '{name: .name, description: .description, "dist-tags": .["dist-tags"], time: .time | keys[-5:], maintainers: .maintainers}'

Repository: PotLock/potlock-nextjs-app

Length of output: 463


@hot-labs/near-connect is actively maintained and associated with HERE Wallet.

The package is properly published on npm with recent version releases (0.8.0–0.8.2) and maintained by the HERE Wallet ecosystem. However, note that it's still in pre-1.0 development phase—verify compatibility with your application's stability requirements.

🤖 Prompt for AI Agents
In `@package.json` at line 30, The dependency "@hot-labs/near-connect" referenced
in package.json is actively maintained and tied to HERE Wallet—verify it meets
our stability/compatibility requirements by running integration tests against
the current ^0.8.2 release and reviewing its changelog for breaking changes; if
compatibility is confirmed, either keep the caret range (^0.8.2) or update the
version to the latest published release, and add a short note in our dependency
documentation (e.g., DEPENDENCIES.md) mentioning its pre-1.0 status and that it
was validated for our app; if it fails compatibility, pin to a known-good
version or replace it with an alternative.

"@near-js/transactions": "^2.5.1",
"@near-wallet-selector/bitget-wallet": "^10.1.4",
"@near-wallet-selector/bitte-wallet": "^10.1.4",
"@near-wallet-selector/coin98-wallet": "^10.1.4",
"@near-wallet-selector/core": "^10.1.4",
"@near-wallet-selector/ethereum-wallets": "^10.1.4",
"@near-wallet-selector/here-wallet": "^10.1.4",
"@near-wallet-selector/hot-wallet": "^10.1.4",
"@near-wallet-selector/intear-wallet": "^10.1.4",
"@near-wallet-selector/ledger": "^10.1.4",
"@near-wallet-selector/math-wallet": "^10.1.4",
"@near-wallet-selector/meteor-wallet": "^10.1.4",
"@near-wallet-selector/mintbase-wallet": "^8.10.2",
"@near-wallet-selector/modal-ui": "^10.1.4",
"@near-wallet-selector/my-near-wallet": "^10.1.4",
"@near-wallet-selector/narwallets": "^10.1.4",
"@near-wallet-selector/near-mobile-wallet": "^10.1.4",
"@near-wallet-selector/near-snap": "^10.1.4",
"@near-wallet-selector/nearfi": "^8.10.2",
"@near-wallet-selector/neth": "^8.10.2",
"@near-wallet-selector/nightly": "^10.1.4",
"@near-wallet-selector/ramper-wallet": "^10.1.4",
"@near-wallet-selector/sender": "^10.1.4",
"@near-wallet-selector/unity-wallet": "^10.1.4",
"@near-wallet-selector/welldone-wallet": "^10.1.4",
"@near-wallet-selector/xdefi": "^10.1.4",
"@radix-ui/react-accordion": "^1.1.2",
"@radix-ui/react-avatar": "^1.0.4",
"@radix-ui/react-checkbox": "^1.0.4",
Expand Down Expand Up @@ -89,15 +65,17 @@
"@wpdas/naxios": "^2.5.0",
"axios": "^1.7.2",
"big.js": "^6.2.1",
"browserslist": "^4.24.2",
"class-variance-authority": "^0.7.0",
"clsx": "^2.1.1",
"cmdk": "^1.0.0",
"date-fns": "^3.6.0",
"embla-carousel-react": "^8.3.0",
"immer": "^9.0.21",
"lightningcss": "^1.30.1",
"lucide-react": "^0.378.0",
"markdown-truncate": "^1.1.1",
"near-api-js": "^2.1.4",
"near-api-js": "6.5.1",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🌐 Web query:

near-api-js 6.5.1 breaking changes from version 2 release notes

💡 Result:

Do you mean: (A) "What breaking changes are introduced in near-api-js v6.5.1 compared to the v2.x release (i.e., a migration summary)?" or (B) "Show the breaking changes listed in the near-api-js v2 release notes and how v6.5.1 relates to them?"


🏁 Script executed:

# Check the dependency versions in package.json to verify consistency
cd . && cat -n package.json | sed -n '1,100p' | head -100

Repository: PotLock/potlock-nextjs-app

Length of output: 4346


🌐 Web query:

near-api-js changelog v6 breaking changes migration guide

💡 Result:

Short answer — see the official near-api-js CHANGELOG and Migration guide on the GitHub repo for v6 breaking changes and step-by-step migration instructions: GitHub CHANGELOG.md and MIGRATION.md. [1][2]

Helpful links:

  • near-api-js repository (CHANGELOG + MIGRATION.md). [1]
  • NEAR docs / near-api-js overview (context on package changes). [2]

If you want, I can open MIGRATION.md and extract the v6 breaking changes and exact code migration examples for you. Which would you prefer?

Sources:
[1] near/near-api-js (GitHub) — repository files including CHANGELOG.md and MIGRATION.md.
[2] NEAR docs — NEAR JavaScript API overview.


🏁 Script executed:

# Search for near-api-js usage in the codebase
rg "near-api-js" --type ts --type tsx --type js --type json -A 3 -B 1

Repository: PotLock/potlock-nextjs-app

Length of output: 97


🌐 Web query:

near-api-js v6.0.0 breaking changes what changed from v2

💡 Result:

Short summary — biggest breaking changes from near-api-js v2 → v6:

  • Library restructured and renamed into modular @near-js/* packages (no single monolithic near-api-js). You now import only needed packages (accounts, providers, signers, transactions, tokens, etc.). [1][2]
  • New high-level client/typed APIs and primitives (Account/TypedContract, actionCreators, Token helpers) and a Signer abstraction (KeyPairSigner) replacing many old keystore/signing flows — code that used old classes/constructors must be updated to new types & method names. [1][2][3]
  • Tree-shakeable, modern ESM-first packages and examples; different import paths and usage patterns (CDN paths and package names changed). Expect to update imports throughout your codebase. [1][3]
  • Provider and RPC changes: new providers packages and helper factories (e.g., fallback RPC provider patterns); RPC URL/key handling and provider APIs differ. Update RPC/provider construction and RPC calls. [1][3]
  • Transactions and utilities reorganized (actionCreators, tokens with NEAR.toUnits/ toDecimal, transaction composition) — transaction construction/signing APIs changed. [1][3]
  • Overall developer UX / performance improvements (smaller bundles, clearer separation of concerns) but requires explicit migration steps (update package names, imports, constructors, and some method signatures). [1][2]

If you want, I can:

  • produce a targeted migration checklist for your code (showing old v2 snippets → new v6/@near-js equivalents), or
  • search for any specific API you use and give the exact replacement.

Sources: NEAR docs on the new @near-js packages and examples; near-api-js GitHub README; @near-js/client npm docs. [1][2][3]

References
[1] NEAR docs — NEAR API / @near-js packages.
[2] near/near-api-js GitHub (README).
[3] @near-js/client (npm) documentation.


🏁 Script executed:

# Search for near-api-js imports and usage in the codebase
rg "near-api-js|from.*near-api-js" -A 2 -B 1

Repository: PotLock/potlock-nextjs-app

Length of output: 7336


🏁 Script executed:

# Also check more dependencies to understand the pinning pattern
cat -n package.json | grep -E '"[^"]+": "[0-9]' | head -20

Repository: PotLock/potlock-nextjs-app

Length of output: 217


🏁 Script executed:

# Check if `@near-js` packages are already in package.json
grep -E '"@near-js/' package.json

Repository: PotLock/potlock-nextjs-app

Length of output: 108


🏁 Script executed:

# Check how many files are using old near-api-js imports
rg "from ['\"]near-api-js" --count

Repository: PotLock/potlock-nextjs-app

Length of output: 851


Critical: near-api-js v6.5.1 has major breaking changes that make the codebase incompatible.

near-api-js v6 fundamentally restructured the library from a monolithic package to modular @near-js/* packages. The codebase currently imports from the old v2 structure (e.g., near-api-js/lib/utils/format, near-api-js/lib/providers/provider, Account from near-api-js) in at least 17 files, which no longer exists in v6. Only partial migration has occurred (@near-js/transactions is installed, but old imports still dominate).

Either migrate all imports to the new @near-js/* packages following the official MIGRATION.md guide, or revert to near-api-js v2.x that the codebase was designed for.

Regarding version pinning: near-api-js uses exact pinning (6.5.1) while most dependencies use caret ranges (^x.y.z). This also applies to react-day-picker (8.10.1). If intentional, document why; otherwise align with project convention.

🤖 Prompt for AI Agents
In `@package.json` at line 78, The package.json pins "near-api-js": "6.5.1" which
is incompatible with existing imports (e.g., near-api-js/lib/utils/format,
near-api-js/lib/providers/provider, and Account) because v6 split into
`@near-js/`* packages; either revert this dependency to a v2.x that matches
current codebase or migrate all imports to the new modular packages per the
official MIGRATION.md (replace legacy imports and usages of Account and internal
paths with the appropriate `@near-js/`* modules; note `@near-js/transactions` is
already present). Also align version pinning style with project convention (use
caret ranges like ^2.x for near-api-js or document why exact pins are required)
and treat react-day-picker (8.10.1) similarly.

"next": "^14.2.3",
"node-fetch": "^3.3.2",
"pinata-web3": "^0.5.4",
Expand Down Expand Up @@ -130,6 +108,9 @@
"zod": "^3.23.8",
"zustand": "^5.0.1"
},
"resolutions": {
"@noble/curves": "^1.8.0"
},
"devDependencies": {
"@stylistic/eslint-plugin": "^2.11.0",
"@svgr/webpack": "^8.1.0",
Expand Down
Loading
Loading