Initialize TypeScript library for Telegram Web App wallet integration

- Added configuration files: .eslintrc.js, .gitignore, .npmrc, .prettierrc, and multiple tsconfig files for different module systems.
- Created package.json with dependencies and scripts for building, testing, and publishing.
- Implemented core functionality in src/ directory, including wallet management, encryption, and storage handling.
- Added README.md for documentation on installation, usage, and development setup.
- Introduced initial types and constants for better type safety and code organization.
This commit is contained in:
odiinnn committed 2025-08-28 13:13:57 +03:00
commit a21ea39c36
19 files changed
+5094

No files matched your search

+78
View File
@@ -0,0 +1,78 @@
{
"name": "@varan-wallet/varan-connect",
"version": "1.0.0",
"description": "A lightweight TypeScript library for Telegram Web App wallet integration with support for both CommonJS and ES modules.",
"type": "commonjs",
"main": "dist/cjs/index.js",
"module": "dist/esm/index.js",
"types": "dist/types/index.d.ts",
"exports": {
".": {
"import": "./dist/esm/index.js",
"require": "./dist/cjs/index.js",
"types": "./dist/types/index.d.ts"
}
},
"files": [
"dist"
],
"publishConfig": {
"access": "public",
"registry": "https://registry.npmjs.org/"
},
"scripts": {
"build": "pnpm run build:cjs && pnpm run build:esm && pnpm run build:types",
"build:cjs": "tsc -p tsconfig.cjs.json",
"build:esm": "tsc -p tsconfig.esm.json",
"build:types": "tsc -p tsconfig.types.json",
"dev": "pnpm run build:esm --watch",
"clean": "rimraf dist",
"prebuild": "pnpm run clean",
"prepublishOnly": "pnpm run build && pnpm run test",
"publish:patch": "pnpm version patch && pnpm publish",
"publish:minor": "pnpm version minor && pnpm publish",
"publish:major": "pnpm version major && pnpm publish",
"test": "jest",
"lint": "eslint src --ext .ts",
"format": "prettier --write \"src/**/*.ts\""
},
"keywords": [
"typescript",
"library",
"telegram",
"webapp",
"wallet",
"injection",
"blockchain",
"polkadot"
],
"author": "",
"license": "MIT",
"repository": {
"type": "git",
"url": "git+https://gitlab.mind-dev.com/varan-wallet/varan-connect.git"
},
"bugs": {
"url": "https://gitlab.mind-dev.com/varan-wallet/varan-connect/issues"
},
"homepage": "https://gitlab.mind-dev.com/varan-wallet/varan-connect#readme",
"dependencies": {
"@twa-dev/sdk": "^8.0.2"
},
"devDependencies": {
"@polkadot/extension-inject": "^0.61.6",
"@polkadot/types": "^16.4.5",
"@types/node": "^20.0.0",
"@typescript-eslint/eslint-plugin": "^6.0.0",
"@typescript-eslint/parser": "^6.0.0",
"eslint": "^8.0.0",
"jest": "^29.0.0",
"prettier": "^3.0.0",
"rimraf": "^5.0.0",
"ts-jest": "^29.0.0",
"typescript": "^5.0.0"
},
"engines": {
"node": ">=16.0.0"
}
}