{"_id":"@alphacarbon/inpage-provider","_rev":"2-e3aa6c3f47cb08dadd7a24979f76cf66","name":"@alphacarbon/inpage-provider","dist-tags":{"latest":"0.1.1"},"versions":{"0.1.0":{"name":"@alphacarbon/inpage-provider","version":"0.1.0","description":"A JavaScript Ethereum provider that connects to the wallet over a stream.","main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=12.0.0"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org/"},"scripts":{"setup":"yarn install && yarn allow-scripts","build":"mkdir -p dist && rm -rf dist/* && tsc --project .","test":"jest","test:watch":"yarn test --watch","lint:eslint":"eslint . --cache --ext js,ts","lint:misc":"prettier '**/*.json' '**/*.md' '!CHANGELOG.md' '**/*.yml' --single-quote --ignore-path .gitignore","lint":"yarn lint:eslint && yarn lint:misc --check","lint:fix":"yarn lint:eslint --fix && yarn lint:misc --write","prepublishOnly":"yarn build && yarn lint && yarn test"},"author":{"name":"AlphaCarbon"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/Alpha-Carbon/inpage-provider.git"},"keywords":["AlphaCarbon","Ethereum","Provider"],"bugs":{"url":"https://github.com/Alpha-Carbon/inpage-provider/issues"},"homepage":"https://github.com/Alpha-Carbon/inpage-provider#readme","dependencies":{"@metamask/object-multiplex":"^1.1.0","@metamask/safe-event-emitter":"^2.0.0","@types/chrome":"^0.0.136","detect-browser":"^5.2.0","eth-rpc-errors":"^4.0.2","extension-port-stream":"^2.0.1","fast-deep-equal":"^2.0.1","is-stream":"^2.0.0","json-rpc-engine":"^6.1.0","json-rpc-middleware-stream":"^3.0.0","pump":"^3.0.0","webextension-polyfill-ts":"^0.25.0"},"devDependencies":{"@lavamoat/allow-scripts":"^1.0.6","@metamask/auto-changelog":"^2.3.0","@metamask/eslint-config":"^7.0.1","@metamask/eslint-config-jest":"^7.0.0","@metamask/eslint-config-nodejs":"^7.0.1","@metamask/eslint-config-typescript":"^7.0.1","@types/jest":"^26.0.23","@types/node":"^14.14.14","@types/pump":"^1.1.0","@types/readable-stream":"^2.3.9","@typescript-eslint/eslint-plugin":"^4.28.1","@typescript-eslint/parser":"^4.28.1","eslint":"^7.29.0","eslint-config-prettier":"^8.1.0","eslint-plugin-import":"^2.23.4","eslint-plugin-jest":"^23.18.0","eslint-plugin-json":"^2.0.1","eslint-plugin-node":"^11.1.0","eslint-plugin-prettier":"^3.4.0","jest":"^26.6.3","jest-chrome":"^0.7.1","prettier":"^2.3.1","ts-jest":"^26.5.6","typescript":"^4.3.5"},"lavamoat":{"allowScripts":{"@lavamoat/preinstall-always-fail":false}},"gitHead":"fb486f27a679dde1b052472e2afb293dee53548e","_id":"@alphacarbon/inpage-provider@0.1.0","_nodeVersion":"14.18.2","_npmVersion":"6.14.15","dist":{"integrity":"sha512-SJUPZ6DQwORaCpuiPTfgKwOO9O2acKnbngA0hhlHk2rbg5/asCvQTr2GjVLCCQRJ6MLHRQhPA4QojJL7y0amag==","shasum":"62385a564dfa18f0bbf80b0edf0fe12f940e10cb","tarball":"https://registry.npmjs.org/@alphacarbon/inpage-provider/-/inpage-provider-0.1.0.tgz","fileCount":35,"unpackedSize":125418,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiMD2qACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmprYw//cdCiSD921R2UxaNit9YNkG8S4RUsYZGAyRA8mSVuBIRsY118\r\nQi1NxuwGTYRHVB1vzlggpF6IOpGGrF+18a8V98JJ0EDXMc+WL8xig8+fsYkP\r\nBCpwic95m5/yicvzn4d768OMUXl429CPkUFSWWFJE6H+mTJ/KzYdxH/k0Ek6\r\nU9yBOnnEwOC6kGwMFhL8fywfDpKY2H46t47d9/YPd6rXlMduX79zfX7QuxWR\r\nJXkkfWG4MBNU86BVfu2c3oNhPSLr3L1daUvUKvBInwp7QO5wmVeJXdrVvIEQ\r\nxlYyp8p2ZBaPMhIa1waYEKnzXs5hslVdqSxvmlZoxUwJQXnMt+OcFa6lfOMC\r\nqKDnuYON1tYPZCIzHpG5KC9iC/nnIm6uGkGTOz2Nt1ap12+KLGNKVTOXjvFX\r\n/aJLajrPhLuU0wbsKl2/yE8KmFZkAXP+A1OCOHE8Z7xn6vioBKvODFHIUgfx\r\nzg61sfQ8kzE0iMaHt9IxLChN9nn6q7/t63irCPe5wdJ6l1QEaekrNtoRCKSY\r\nAuF8RjZrYX4IWyJSYm9GtCFmWr/1P/w96ckARAMecg3QkWMaQhSQMdVcGKNO\r\nYwg4/b8bE/N4CrsYbSnsJ87CrRfvDUoC53Gz6LXjO165cTc3CvwM2/xwGz9f\r\n78AuaqP8HkezGu8TrZeW2MyIr7leK/6JTUI=\r\n=cfhP\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBWj/4CPbUb718hLXiQrjj3Ixnx8ziVYg3CB7zdIf3X9AiEA8TLVDUgds4bN32PGhRzqEJXe6uTYj7tBy3V21dYvPPE="}]},"_npmUser":{"name":"mayone","email":"mayone321@gmail.com"},"directories":{},"maintainers":[{"name":"mayone","email":"mayone321@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/inpage-provider_0.1.0_1647328682010_0.940506758004586"},"_hasShrinkwrap":false},"0.1.1":{"name":"@alphacarbon/inpage-provider","version":"0.1.1","description":"A JavaScript Ethereum provider that connects to the wallet over a stream.","main":"dist/index.js","types":"dist/index.d.ts","engines":{"node":">=12.0.0"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org/"},"scripts":{"setup":"yarn install && yarn allow-scripts","build":"mkdir -p dist && rm -rf dist/* && tsc --project .","test":"jest","test:watch":"yarn test --watch","lint:eslint":"eslint . --cache --ext js,ts","lint:misc":"prettier '**/*.json' '**/*.md' '!CHANGELOG.md' '**/*.yml' --single-quote --ignore-path .gitignore","lint":"yarn lint:eslint && yarn lint:misc --check","lint:fix":"yarn lint:eslint --fix && yarn lint:misc --write","prepublishOnly":"yarn build && yarn lint && yarn test"},"author":{"name":"AlphaCarbon"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/Alpha-Carbon/inpage-provider.git"},"keywords":["AlphaCarbon","Ethereum","Provider"],"bugs":{"url":"https://github.com/Alpha-Carbon/inpage-provider/issues"},"homepage":"https://github.com/Alpha-Carbon/inpage-provider#readme","dependencies":{"@metamask/object-multiplex":"^1.1.0","@metamask/safe-event-emitter":"^2.0.0","@types/chrome":"^0.0.136","detect-browser":"^5.2.0","eth-rpc-errors":"^4.0.2","extension-port-stream":"^2.0.1","fast-deep-equal":"^2.0.1","is-stream":"^2.0.0","json-rpc-engine":"^6.1.0","json-rpc-middleware-stream":"^3.0.0","pump":"^3.0.0","webextension-polyfill-ts":"^0.25.0"},"devDependencies":{"@lavamoat/allow-scripts":"^1.0.6","@metamask/auto-changelog":"^2.3.0","@metamask/eslint-config":"^7.0.1","@metamask/eslint-config-jest":"^7.0.0","@metamask/eslint-config-nodejs":"^7.0.1","@metamask/eslint-config-typescript":"^7.0.1","@types/jest":"^26.0.23","@types/node":"^14.14.14","@types/pump":"^1.1.0","@types/readable-stream":"^2.3.9","@typescript-eslint/eslint-plugin":"^4.28.1","@typescript-eslint/parser":"^4.28.1","eslint":"^7.29.0","eslint-config-prettier":"^8.1.0","eslint-plugin-import":"^2.23.4","eslint-plugin-jest":"^23.18.0","eslint-plugin-json":"^2.0.1","eslint-plugin-node":"^11.1.0","eslint-plugin-prettier":"^3.4.0","jest":"^26.6.3","jest-chrome":"^0.7.1","prettier":"^2.3.1","ts-jest":"^26.5.6","typescript":"^4.3.5"},"lavamoat":{"allowScripts":{"@lavamoat/preinstall-always-fail":false}},"gitHead":"724ea98c9bdd7a4533cc4ca356f3c83796cd66d5","_id":"@alphacarbon/inpage-provider@0.1.1","_nodeVersion":"14.18.2","_npmVersion":"6.14.15","dist":{"integrity":"sha512-Atsw+I2xx2QrCLypXpgvlDSE/U8oHD96J3oZCrjyu9XEDMbCIyW2KHzLDsUhxGfSxKzv19EmT+W1fsP8UWxP9Q==","shasum":"ab7d8bdf1584ecaf7c7eee98c1d3ea2d97770044","tarball":"https://registry.npmjs.org/@alphacarbon/inpage-provider/-/inpage-provider-0.1.1.tgz","fileCount":35,"unpackedSize":125864,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIB6yp7CtEZ6S9Q5slVT4oyi+K807cx4bnRipDOjiwR8nAiBK+9aDO6tsM6vZKCuhx/F0YxbtfLAR0tf8v1enuuvdBQ=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJig0alACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmq8gRAAnTDLd0b5E4gJRcRdfIWO4tD+H++Ixnag+RcGD1Rayt5MlLiL\r\n2iO5nn+m8MfGDzzz397X68TRHeyidIlZmUUcXTilLAN6VHAkP8rW1SD4xrlx\r\nQ3N9R0LGA/oNPpy/9FoUn4Lnw8xHPaAF0TOi6A3H5QiFzq6O8OHCa5B4g+Td\r\n2+nXyfaUsQsvp0ZLszLXNxpXtT/2DDQD46uluaiKQa29FkLKWsDtqFU/UWDn\r\nKdnLE0/BWfzZF7WaFvItg19cePt1+T23qWYtuwYe9tyemrE8wd4M1zDgrt2d\r\n/ZTGqJwB7ZO11aDUh91P3XIoxG3QhuCk2nJChS9g8sRtwh8ewfGRwdrRloHF\r\nyMa2O0Epmi7bBBoF/t3IITQqh/XZQBcRGzqoECg9icPeZBeqfK7I/Sug81s1\r\nhM3lBDKOlnb+xG3SmVseULUoUZvqpTx0ZAJyCuPxj/0mxV98ztCtcggrosFB\r\nG08ozXOoLrp1njqN8ImnA2DH+EDTMeLu//mwvEpeOQBgSOTeWBTEDiC1FLsQ\r\nBhJ2iJElp4Wk0B8IdE+fKEk7euuCetQbdRkeyfvYRERKxEKUB9LarxqVR8t5\r\nX9on2rLNXrYuKzZicOYEN+d9bQXBSpC+haiAdBHISH2kHuarwuIfcdQUgoWX\r\nJz8nA2zOp3kvylQyNu4N/MR3eQeAK0emYOs=\r\n=JusB\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"mayone","email":"mayone321@gmail.com"},"directories":{},"maintainers":[{"name":"mayone","email":"mayone321@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/inpage-provider_0.1.1_1652770469667_0.8885384720087881"},"_hasShrinkwrap":false}},"time":{"created":"2022-03-15T07:18:01.951Z","0.1.0":"2022-03-15T07:18:02.157Z","modified":"2022-05-17T06:54:29.916Z","0.1.1":"2022-05-17T06:54:29.835Z"},"maintainers":[{"name":"mayone","email":"mayone321@gmail.com"}],"description":"A JavaScript Ethereum provider that connects to the wallet over a stream.","homepage":"https://github.com/Alpha-Carbon/inpage-provider#readme","keywords":["AlphaCarbon","Ethereum","Provider"],"repository":{"type":"git","url":"git+https://github.com/Alpha-Carbon/inpage-provider.git"},"author":{"name":"AlphaCarbon"},"bugs":{"url":"https://github.com/Alpha-Carbon/inpage-provider/issues"},"license":"MIT","readme":"# MetaMask Providers\n\nThe Ethereum provider object injected by MetaMask into various environments.\nContains a lot of implementation details specific to MetaMask, and is probably\nnot suitable for out-of-the-box use with other wallets.\n\nThe `BaseProvider` implements the Ethereum JavaScript provider specification, [EIP-1193](https://eips.ethereum.org/EIPS/eip-1193). `MetamaskInpageProvider` implements [EIP-1193](https://eips.ethereum.org/EIPS/eip-1193) and legacy interfaces.\n\n## Usage\n\n```javascript\nimport { initializeProvider } from '@metamask/providers';\n\n// Create a stream to a remote provider:\nconst metamaskStream = new LocalMessageDuplexStream({\n  name: 'inpage',\n  target: 'contentscript',\n});\n\n// this will initialize the provider and set it as window.ethereum\ninitializeProvider({\n  connectionStream: metamaskStream,\n});\n\nconst { ethereum } = window;\n```\n\n### Types\n\nTypes are exposed at `index.d.ts`.\nThey require Node.js `EventEmitter` and `Duplex` stream types, which you can grab from e.g. [`@types/node`](https://npmjs.com/package/@types/node).\n\n### Do Not Modify the Provider\n\nThe Provider object should not be mutated by consumers under any circumstances.\nThe maintainers of this package will neither fix nor take responsbility for bugs caused by third parties mutating the provider object.\n\n## Contributing\n\n### Setup\n\n- Install [Node.js](https://nodejs.org) version 12\n  - If you are using [nvm](https://github.com/creationix/nvm#installation) (recommended) running `nvm use` will automatically choose the right node version for you.\n- Install [Yarn v1](https://yarnpkg.com/en/docs/install)\n- Run `yarn setup` to install dependencies and run any requried post-install scripts\n  - **Warning:** Do not use the `yarn` / `yarn install` command directly. Use `yarn setup` instead. The normal install command will skip required post-install scripts, leaving your development environment in an invalid state.\n\n### Testing and Linting\n\nRun `yarn test` to run the tests once. To run tests on file changes, run `yarn test:watch`.\n\nRun `yarn lint` to run the linter, or run `yarn lint:fix` to run the linter and fix any automatically fixable issues.\n\n### Release & Publishing\n\nThe project follows the same release process as the other libraries in the MetaMask organization:\n\n1. Create a release branch\n   - For a typical release, this would be based on `main`\n   - To update an older maintained major version, base the release branch on the major version branch (e.g. `1.x`)\n2. Update the changelog\n3. Update version in package.json file (e.g. `yarn version --minor --no-git-tag-version`)\n4. Create a pull request targeting the base branch (e.g. `main` or `1.x`)\n5. Code review and QA\n6. Once approved, the PR is squashed & merged\n7. The commit on the base branch is tagged\n8. The tag can be published as needed\n","readmeFilename":"README.md"}