{"id":18245000,"url":"https://github.com/edgeapp/edge-core-js","last_synced_at":"2025-10-24T20:37:14.781Z","repository":{"id":38083416,"uuid":"60286381","full_name":"EdgeApp/edge-core-js","owner":"EdgeApp","description":"Edge Core Javascript implementation. Provides Edge account and wallet functionality for NodeJS/HTML/React Native apps","archived":false,"fork":false,"pushed_at":"2025-05-13T00:48:09.000Z","size":6532,"stargazers_count":76,"open_issues_count":19,"forks_count":53,"subscribers_count":19,"default_branch":"master","last_synced_at":"2025-05-13T01:32:45.619Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://edge.app","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/EdgeApp.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2016-06-02T18:07:21.000Z","updated_at":"2025-05-13T00:48:10.000Z","dependencies_parsed_at":"2023-02-15T03:16:45.247Z","dependency_job_id":"6b37c351-fbd2-4d1b-8da7-469ea4c5baba","html_url":"https://github.com/EdgeApp/edge-core-js","commit_stats":{"total_commits":2336,"total_committers":32,"mean_commits":73.0,"dds":"0.20804794520547942","last_synced_commit":"4e1d227952437b6c6a3476922396eb0a26683645"},"previous_names":["airbitz/airbitz-core-js"],"tags_count":314,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EdgeApp%2Fedge-core-js","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EdgeApp%2Fedge-core-js/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EdgeApp%2Fedge-core-js/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/EdgeApp%2Fedge-core-js/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/EdgeApp","download_url":"https://codeload.github.com/EdgeApp/edge-core-js/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254544146,"owners_count":22088807,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-05T09:18:34.233Z","updated_at":"2025-10-24T20:37:14.665Z","avatar_url":"https://github.com/EdgeApp.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Edge Core\n\nThis library implements the Edge login system. It runs inside a client application, and provides zero-knowledge backup for cryptographic keys and other secrets via a familiar password-based login system.\n\n[![Build Status](https://travis-ci.com/EdgeApp/edge-core-js.svg?branch=master)](https://travis-ci.com/EdgeApp/edge-core-js)\n[![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)\n[![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square)](https://github.com/prettier/prettier)\n\n## Documentation\n\nWe have documentation at https://developer.airbitz.co/javascript/, but our [Flow types](./src/types/types.js) are the best, most up-to-date reference for what this library contains.\n\n## Account Management UI\n\nTo quickly get up and running with the UI for account creation, login, and management, use [edge-login-ui-web](https://github.com/EdgeApp/edge-login-ui/tree/develop/packages/edge-login-ui-web) for the web or [edge-login-ui-rn](https://github.com/EdgeApp/edge-login-ui/tree/develop/packages/edge-login-ui-rn) for React Native.\n\n## Setup\n\nAdd this library to your project using `npm install --save edge-core-js`.\n\n### Node.js \u0026 Browsers\n\nTo create an `EdgeContext` object, which provides various methods for logging in and creating account, do something like this:\n\n```javascript\nconst context = await makeEdgeContext({\n  apiKey: '...', // Get this from our support team\n  appId: 'com.your-app',\n  plugins: {\n    // Configure currencies, exchange rates, and swap providers you want to use:\n    'bitcoin': true\n  }\n})\n```\n\nThe core uses various plugins to provide its currency, exchange rate, and swap features. These plugins ship separately, and are designed to load in parallel with the core:\n\n```js\nimport { addEdgeCorePlugins, lockEdgeCorePlugins } from 'edge-core-js'\nimport exchangePlugins from 'edge-exchange-plugins'\nimport bitcoinPlugins from 'edge-currency-bitcoin'\nimport currencyPlugins from 'edge-currency-accountbased'\n\naddEdgeCorePlugins(exchangePlugins)\naddEdgeCorePlugins(bitcoinPlugins)\naddEdgeCorePlugins(currencyPlugins)\nlockEdgeCorePlugins()\n```\n\nIf the core seems to hang forever when logging in, you probably forgot to call `lockEdgeCorePlugins`.\n\nPlease note that edge-core-js uses modern JavaScript syntax features such as `async`, so you may need to run the library through [Babel](https://babeljs.io/) if you plan to run it in a browser. Node 10+ supports these features natively.\n\n### React Native\n\nEdge-core-js directly supports React Native v0.60+ with autolinking. Simply add edge-core-js to your application, and React Native will link the necessary native modules \u0026 assets.\n\nTo create an `EdgeContext` object, you need to mount a component:\n\n```jsx\n\u003cMakeEdgeContext\n  // Get this from our support team:\n  apiKey=\"...\"\n  appId=\"com.your-app\"\n\n  // Configure currencies and swap providers you want to use:\n  plugins={{\n    'bitcoin': true\n  }}\n  pluginUris={[\n    \"edge-currency-plugins.js\",\n    \"edge-exchange-plugins.js\"\n  ]}\n\n  // Called when the core is done loading:\n  onLoad={edgeContext =\u003e {}}\n  onError={error =\u003e {}}\n/\u003e\n```\n\nThe core itself runs inside a hidden WebView, which this `MakeEdgeContext` component mounts \u0026 manages.\n\nThe core creates a `\u003cscript\u003e` tag for each source file in the `pluginUris` array. For this to work, you need to add these plugin files to your app's native asset bundle, which is located at `/android/app/src/main/assets/` on Android. For iOS, drag these files into the \"Resources\" section of your Xcode project.\n\nTo debug the core, run `yarn start` inside the edge-core-js project, and then pass a `debug={true}` property to the `MakeEdgeContext` component. This tells the WebView to load the core from a local development server.\n\n## Contributing\n\nRun `yarn` to download dependencies, and then run `yarn prepare` to build the library.\n\nUse `yarn verify` to run all our code-quality tools. All sources are in the [JavaScript Standard Style](http://standardjs.com/) + [Prettier](https://prettier.io/). We check files prior to each commit, so if you have formatting issues, you can run `yarn fix` to fix them automatically.\n\nIf you use Visual Studio Code, consider installing the [ESLint](https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint) extension. This will give you nice error highlighting as you work, along with quick fixes for formatting issues.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fedgeapp%2Fedge-core-js","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fedgeapp%2Fedge-core-js","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fedgeapp%2Fedge-core-js/lists"}