Git Product home page Git Product logo

chrome-extension-development's Introduction

Hi there 👋

  • 🔭 I’m currently working on 🐯tigerbrokers, and we are looking for Nodejs/Reactjs/Python/Java/Mac&Windows/Android/IOS developers to join us.
  • 🔭 当前在🐯老虎证券工作,我们长期招聘 Nodejs、Reactjs、Python、Java、Mac和Windows、Android、IOS 开发工程师,欢迎加入

chrome-extension-development's People

Contributors

qiqiboy avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

chrome-extension-development's Issues

screenshots

2017-07-15 23 43 39

![2017-07-15 23 43 10](https://user-images.githubusercontent.com/3774036/28240613-b8545958-69b7-11e7-8098-6bae97b0ae28.png) ![2017-07-15 23 42 55](https://user-images.githubusercontent.com/3774036/28240611-b7a353c4-69b7-11e7-9be9-66343f56fb96.png)

2017-07-15 23 42 47

![2017-07-15 23 42 32](https://user-images.githubusercontent.com/3774036/28240610-b7533ac4-69b7-11e7-8423-0179cadc7a93.png)

如何实现扩展的自动重载?

本项目代码开发环境使用webpack构建,同时使用了webpack-dev-server来创建了一个默认端口3666的本地开发服务器。

开发时所有入口文件均加入了一个hotClient的js(修改自react-dev-utils)。该代码中通过websocket与开发服务器连接,接受代码变动的推送。

当发现代码有变动时,会通过 background 环境,执行下面的动作:

  • 查找当前窗口所有tab,是不是有打开的扩展管理页面(chrome://extensions)
  • 如果找到该tab,则刷新该tab;否则创建一个固定tab打开扩展管理页面,然后刷新该tab。

扩展管理页面刷新就会自动重载所有的开发状态的tab。借此,就完成了代码变动到扩展重载的功能实现。

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.