OLD | NEW |
1 Adblock Plus for Chrome, Opera, Microsoft Edge and Firefox | 1 Adblock Plus for Chrome, Opera, Microsoft Edge and Firefox |
2 ========================================================== | 2 ========================================================== |
3 | 3 |
4 This repository contains the platform-specific Adblock Plus source code for | 4 This repository contains the platform-specific Adblock Plus source code for |
5 Chrome, Opera, Microsoft Edge and Firefox. It can be used to build | 5 Chrome, Opera, Microsoft Edge and Firefox. It can be used to build |
6 Adblock Plus for these platforms, generic Adblock Plus code will be extracted | 6 Adblock Plus for these platforms, generic Adblock Plus code will be extracted |
7 from other repositories automatically (see _dependencies_ file). | 7 from other repositories automatically (see _dependencies_ file). |
8 | 8 |
9 Note that the Firefox extension built from this repository is the new | 9 Note that the Firefox extension built from this repository is the new |
10 [WebExtension](https://developer.mozilla.org/en-US/Add-ons/WebExtensions). | 10 [WebExtension](https://developer.mozilla.org/en-US/Add-ons/WebExtensions). |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
53 | 53 |
54 ./build.py -t chrome devenv | 54 ./build.py -t chrome devenv |
55 ./build.py -t edge devenv | 55 ./build.py -t edge devenv |
56 ./build.py -t gecko-webext devenv | 56 ./build.py -t gecko-webext devenv |
57 | 57 |
58 This will create a _devenv.*_ directory in the repository. You can load the | 58 This will create a _devenv.*_ directory in the repository. You can load the |
59 directory as an unpacked extension, under _chrome://extensions_ in Chrome, | 59 directory as an unpacked extension, under _chrome://extensions_ in Chrome, |
60 under _about:debugging_ in Firefox or in _Extensions_ menu in Microsoft Edge, | 60 under _about:debugging_ in Firefox or in _Extensions_ menu in Microsoft Edge, |
61 after enabling extension development features in _about:flags_. | 61 after enabling extension development features in _about:flags_. |
62 After making changes to the source code re-run the command to update the | 62 After making changes to the source code re-run the command to update the |
63 development environment. In Chrome and Firefox the extension should reload | 63 development environment. The extension should reload automatically after a |
64 automatically after a few seconds. | 64 few seconds. |
65 | |
66 Builds for Microsoft Edge do not automatically detect changes, so after | |
67 rebuilding the extension you should manually force reloading it in Edge by | |
68 hitting the _Reload Extension_ button. | |
69 | 65 |
70 Running the unit tests | 66 Running the unit tests |
71 ---------------------- | 67 ---------------------- |
72 | 68 |
73 To verify your changes you can use the unit test suite located in the _qunit_ | 69 To verify your changes you can use the unit test suite located in the _qunit_ |
74 directory of the repository. In order to run the unit tests go to the | 70 directory of the repository. In order to run the unit tests go to the |
75 extension's Options page, open the JavaScript Console and type in: | 71 extension's Options page, open the JavaScript Console and type in: |
76 | 72 |
77 location.href = "qunit/index.html"; | 73 location.href = "qunit/index.html"; |
78 | 74 |
79 The unit tests will run automatically once the page loads. | 75 The unit tests will run automatically once the page loads. |
80 | 76 |
81 Linting | 77 Linting |
82 ------- | 78 ------- |
83 | 79 |
84 You can lint the code using [ESLint](http://eslint.org). | 80 You can lint the code using [ESLint](http://eslint.org). |
85 | 81 |
86 eslint *.js lib/ qunit/ ext/ chrome/ | 82 eslint *.js lib/ qunit/ ext/ chrome/ |
87 | 83 |
88 You will need to set up ESLint and our configuration first, see | 84 You will need to set up ESLint and our configuration first, see |
89 [eslint-config-eyeo](https://hg.adblockplus.org/codingtools/file/tip/eslint-conf
ig-eyeo) | 85 [eslint-config-eyeo](https://hg.adblockplus.org/codingtools/file/tip/eslint-conf
ig-eyeo) |
90 for more information. | 86 for more information. |
OLD | NEW |