()MetaMask Browser Extension

https://github.com/MetaMask/metamask-extension

这就是整个metamask的源码所在之处,好好看看

https://metamask.github.io/metamask-extension/这是源码的类、对象等的详细解释

1)了解整个代码的学习流程,看:https://github.com/MetaMask/metamask-extension/blob/develop/docs/porting_to_new_environment.md

Guide to Porting MetaMask to a New Environment

2)为了能够更好地学习metamask的实现代码,首先我们要先学习stream

stream-handbook

英文版:https://github.com/MetaMask/metamask-extension/blob/develop/docs/porting_to_new_environment.md

中文版:https://github.com/jabez128/stream-handbook

3)就比如说之前游戏是想说直接将metamask嵌入到游戏中,这样就不用下载插件了,而且不是自己有一个服务器吗,然后可以像将以太坊主网

一样将这个服务器上的区块链网络设置为上面的一个可选项,更甚至就是玩这个游戏就只有我们这个服务器环境的选择,基本上就是会直接连上我们的服务器

下面就是如果你要添加一个定制的网络的话,你需要更改的文件有哪一些

Adding Custom Networks

To add another network to our dropdown menu, make sure the following files are adjusted properly:

app/scripts/config.js
app/scripts/lib/buy-eth-url.js
ui/app/app.js
ui/app/components/buy-button-subview.js
ui/app/components/drop-menu-item.js
ui/app/components/network.js
ui/app/components/transaction-list-item.js
ui/app/config.js
ui/app/css/lib.css
ui/lib/account-link.js
ui/lib/explorer-link.js

You will need:

  • The network ID
  • An RPC Endpoint url
  • An explorer link
  • CSS for the display icon

metamask源码学习导论的更多相关文章

  1. metamask源码学习-ui/index.js

    The UI-即上图左下角metamask-ui部分,即其图形化界面 The MetaMask UI is essentially just a website that can be configu ...

  2. metamask源码学习-inpage.js

    The most confusing part about porting MetaMask to a new platform is the way we provide the Web3 API ...

  3. metamask源码学习-controller-transaction

    ()metamask-extension/app/scripts/controllers/transactions Transaction Controller is an aggregate of ...

  4. metamask源码学习-contentscript.js

    When a new site is visited, the WebExtension creates a new ContentScript in that page's context, whi ...

  5. metamask源码学习-background.js

    这个就是浏览器后台所进行操作的地方了,它就是页面也区块链进行交互的中间部分. metamask-background描述了为web扩展单例的文件app/scripts/background.js.该上 ...

  6. metamask源码学习-metamask-controller.js

    The MetaMask Controller——The central metamask controller. Aggregates other controllers and exports a ...

  7. metamask源码学习-controllers-network

    https://github.com/MetaMask/metamask-extension/tree/master/app/scripts/controllers/network metamask- ...

  8. Java集合专题总结(1):HashMap 和 HashTable 源码学习和面试总结

    2017年的秋招彻底结束了,感觉Java上面的最常见的集合相关的问题就是hash--系列和一些常用并发集合和队列,堆等结合算法一起考察,不完全统计,本人经历:先后百度.唯品会.58同城.新浪微博.趣分 ...

  9. jQuery源码学习感想

    还记得去年(2015)九月份的时候,作为一个大四的学生去参加美团霸面,结果被美团技术总监教育了一番,那次问了我很多jQuery源码的知识点,以前虽然喜欢研究框架,但水平还不足够来研究jQuery源码, ...

随机推荐

  1. 通过kubernetes构建ela服务

    一.kubernetes 通过yaml 创建pod与service apiVersion: extensions/v1beta1 kind: Deployment metadata: name: el ...

  2. blfs(systemd版本)学习笔记-编译安装sudo并创建普通用户配置sudo权限

    我的邮箱地址:zytrenren@163.com欢迎大家交流学习纠错! blfs书中sudo的安装配置章节:http://www.linuxfromscratch.org/blfs/view/stab ...

  3. Breeze 部署 Kubernetes 1.12.1高可用集群

    今天看文章介绍了一个开源部署 K8S 的工具,有空研究下~ Github 地址: https://github.com/wise2c-devops/breeze

  4. js中数组常用的api 及其作用

  5. java Name [jdbc/myjavadb] is not bound in this Context. Unable to find [jdbc].

    一.出错时的情况: 首先,这是一个servlet项目 1.项目的web.xml配置了:(后来发现不配置这个也行,但是tomcat一定要配置) <resource-ref> <desc ...

  6. Gartner2017年BI研究计划曝光,来看看他研究的都是啥?

    文 | 水手哥 本文出自:知乎专栏<帆软数据应用研究院>——数据干货&资讯集中地   近日,Gartner发布了<Analytics and Business Intelli ...

  7. Linux高可靠技术

    1.进程挂死时,有后台监控程序检测重新拉起. 2.进程占用系统资源超过ulimit限定的资源时,会被ulimit杀死,同时配合后台监控程序,重新拉起进程,实现进程可靠性. 3.Linux系统的高可靠性 ...

  8. android 保存图片,及将图片更新到图库

    **保存图片 public static File saveImage(Bitmap bmp) { File appDir = new File(Environment.getExternalStor ...

  9. js,H5本地存储

    //存储本地存储----setItem(存储名称,数据名称) var c={name:"man",sex:"woman"}; localStorage.setI ...

  10. (后端)出现org.hibernate.NonUniqueResultException的原因即解决办法

    百度出来的资料解决问题: 一个问题,事务处理完毕以后页面没有刷新.刚开始以为是前台js的问题,后来检查js没有任何问题,跟踪到后台发现后台报错了,错误信息如下:org.hibernate.NonUni ...