-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feedback from building an extension based on your (awesome) project. #28
Comments
1. Be able to listen from browser eventsMy first need was to be able to dispatch action from a browser event. Adding a listenerFor example I have a listener for the web request, so I create a import { webRequestLaunched } from '../actions/browsing';
class WebRequestListener {
constructor(vAPI) { //the vAPI is a façade for the chrome api
this.vAPI = vAPI;
}
listen(store) {
this.vAPI.net.onBeforeRequest = {
urls: [
'http://*/*',
'https://*/*'
],
callback: (details) => {
store.dispatch(webRequestLaunched(details))
}};
}
}
export default WebRequestListener; Registering the listenersI have created a import WebRequestListener from './webRequest'
export default {
init: function(vAPI, store) {
new WebRequestListener(vAPI).listen(store);
}
} Then in the |
2. Having different views/context for the contentScript and PopupIn our future extension, some configuration will be made through the popup. containers/
PopUp/
Root.js
App.js
ContentScript/
Root.js
App.js
... With this structure I am able to build very different view for each part of the extension. |
Hey, That's an amazing idea to share experience of implementation here! Thanks a lot for sharing it! I use this boilerplate for More implementations will come later. |
Hello,
First of all, a big thank you for your incredible project !
(disclaimer, I'm a not a native english speaker... please forgive my mistakes :))
I will update this issue throughout the project with some of the modifications I made to adapt the seed.
The project I work on, is a browser extension for a french startup: http://www.lmem.net
I made this issue to share thought about building a more complexe extension based on your seed. Maybe this can be helpful for other extension creator.
The text was updated successfully, but these errors were encountered: