You might also wanna read ./architecture.org
If you are looking to contribute to spookfox’s development, please follow this guide to setup a development environment.
Assumption: you are on a Linux machine, and have cloned this repo.
If you don’t have Nix installed, you will need to make sure that following
software are available in your $PATH
.
- Node.js, for building the spookfox add-on
If you have Nix installed, you can just do nix-shell
to drop into an already
setup development environment. Or if you are using direnv, just do a direnv
allow
to achieve the same.
cd spookfox-addon
yarn
yarn start
- Install in Firefox
- Open Firefox
- Go to about:addons
- Click on the gear icon and select ”Debug Add-Ons”
- Click on ”Load Temporary Add-on” button
- Navigate to the
spookfox-addon/dist
directory, and clickOpen
Any changes you make to typescript/html/scss now will automatically rebuild. But
you will still need to click on Reload
button on Debug Add-Ons firefox page.
You can use straight.el to install it directly from where you’ve clone this repo.
(use-package spookfox
:straight (spookfox :type git
:local-repo "~/Documents/work/spookfox"
:files ("lisp/*.el" "lisp/apps/*.el"))
:config
(spookfox-init))
This is how I install it in my config.
- Access addon’s developer console
In Firefox go to about:addons, click Gear Icon > Debug Addons > Inspect(in Spookfox box). This will open a developer console where you can see messages logged by the addon. There is also a global variable
spookfox
(instance ofSpookfox
class) available which you can play with. - Log state-changing events
To see various levels of logged messages, please set
SPOOKFOX_DEBUG
to a number b/w 0 and 2 inlocalStorage
i.elocalStorage.setItem('SPOOKFOX_DEBUG', 1)
0 -> Log errors 1 -> Log information 2 -> Log for debugging