Files
ui/package.json
rob thijssen f2a1ab3a72 build: consume the forked @polkadot packages from the registry, drop the scaffolding
Removes every workaround the symlink approach needed, and reverts tsconfig to
upstream's exactly.

The three forked packages — @polkadot/{networks,util-crypto,keyring} — are now
pinned to Gitea tarball URLs in resolutions. @polkadot/util is not, because this
fork does not modify it; it comes from npm like the rest of the scope.

Tarball URLs rather than routing the @polkadot scope to Gitea, because the scope
is mostly *not* forked: routing it would send yarn looking for dozens of packages
that are not there. @quantus is routed as a whole scope in .yarnrc.yml, which is
safe because we own every name in it.

Four things go away, all of which existed for one reason — node resolves a portal
or link symlink to its realpath, after which @polkadot/util-crypto resolved inside
*common's* tree, where it is a workspace source directory with no exports map:

  - resolutions pointing four packages at ../common/packages/*/build
  - tsconfig.base.json `*.d.ts` path mappings, needed because NodeNext will not
    infer an extension for a bare path and looked for a `types` directory
  - tsconfig.json overriding those with a runtime `.js` view, because
    @polkadot/dev-ts reads that file and tried to import a declaration file as a
    module
  - --preserve-symlinks in the test scripts

Also drops fflate and @quantus/crypto from ui-keyring's devDependencies; they were
there only because `link:` does not install its target's dependencies.

`yarn lint` now reports 0 errors, down from 25 on pristine upstream. Those were
no-unsafe-assignment and no-unsafe-argument on values that were `any` purely
because the types did not resolve.

Refs quantus/extension#2, quantus/ui#1

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012uDUodEcRbBwNRi3UCmw8f
2026-09-15 11:08:43 +03:00

51 lines
1.6 KiB
JSON

{
"author": "Jaco Greeff <jacogr@gmail.com>",
"bugs": "https://github.com/polkadot-js/ui/issues",
"engines": {
"node": ">=18.14"
},
"homepage": "https://github.com/polkadot-js/ui#readme",
"license": "Apache-2.0",
"packageManager": "yarn@4.5.1",
"private": true,
"repository": {
"type": "git",
"url": "https://github.com/polkadot-js/ui.git"
},
"sideEffects": false,
"type": "module",
"version": "3.16.7",
"versions": {
"git": "3.16.7",
"npm": "3.16.7"
},
"workspaces": [
"packages/*"
],
"scripts": {
"build": "polkadot-dev-build-ts",
"build:release": "polkadot-ci-ghact-build",
"build:rollup": "polkadot-exec-rollup --config",
"clean": "polkadot-dev-clean-build",
"lint": "polkadot-dev-run-lint",
"postinstall": "polkadot-dev-yarn-only",
"test": "polkadot-dev-run-test --env browser",
"test:one": "polkadot-dev-run-test --env browser"
},
"devDependencies": {
"@polkadot/dev": "^0.83.3",
"@polkadot/x-bundle": "^14.0.3",
"@types/node": "^22.10.5",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-is": "^18.2.0",
"react-native": "^0.73.1"
},
"resolutions": {
"@polkadot/keyring": "https://git.lair.cafe/api/packages/quantus/npm/%40polkadot%2Fkeyring/-/14.0.3/keyring-14.0.3.tgz",
"@polkadot/networks": "https://git.lair.cafe/api/packages/quantus/npm/%40polkadot%2Fnetworks/-/14.0.3/networks-14.0.3.tgz",
"@polkadot/util-crypto": "https://git.lair.cafe/api/packages/quantus/npm/%40polkadot%2Futil-crypto/-/14.0.3/util-crypto-14.0.3.tgz",
"typescript": "5.5.4"
}
}