I. Build a Development Environment
Before you start development, you must first build the environment required for extension development. Firefox sets the user's personal information, including settings,
All installed extensions are saved in a profile. By default, the profile named default is used. By creating
The profile used for development does not affect normal use or personal information.
Create a profile:
Step: 1. Enter cmd in the Start Menu
2. Start "% ProgramFiles % \ Mozilla Firefox \ firefox.exe"-no-remote-P Dev
3. To create a configuration file, just write a name and the next step is OK.
4. After the creation is complete, start Firefox.
Ii. Install the Firefox plug-in
The plug-ins include Venkman, extension developer's extension, console2, chrome list, execute JS, xpcomviewer, and
Firebug
For more development help plug-ins, see: https://developer.mozilla.org/en/Setting_up_extension_development_environment
Installation Method:
Get plug-ins
3. Configure Firefox Parameters
Enter: About: config in the address bar.
Javascript. Options. showinconsole = true // display JavaScript error information on the error Console
Javascript. Options. Strict = true // enable strict JavaScript warning information on the error Console
Refer to another articleArticleIn
Http://www.ibm.com/developerworks/cn/web/wa-lo-firefox-ext/index.html
the following two parameters cannot be found in about: config. You need to set them in c: \ Documents ents and Settings \ Administrator \ Application Data \ Mozilla \ Firefox \ profiles \ rbl3tisg. dev
User. in the JS
file, if the file does not exist, create it, but the file will not be available in Versions later than Firefox 3.0. Use prefs. the JS file is replaced by
Add
user_pref ("nglayout. debug. disable_xul_cache ", true);
// disable XUL cache, therefore, you do not need to reload the XUL file to modify the window and dialog box
user_pref ("browser. dom. window. dump. enabled ", true);
// allow dump () statements to output information to the standard console
the basic development environment has been set up.
See
https://developer.mozilla.org/cn/Setting_up_extension_development_environment
it is best to create a shortcut on the desktop:
directory:
"C: \ Program Files \ Mozilla Firefox \ firefox.exe "-no-remote-P" Dev "