Thanks for your interest in contributing to fiftyone-plugins
!
If you plan to contribute a PR, please check install the pre-commit hooks before committing:
pre-commit install
You can manually lint a file if necessary like so:
# Manually run linting configured in the pre-commit hook
pre-commit run --files <file>
When developing locally, you must make your source install of this repository available to FiftyOne.
A convenient way to do that is to symlink this repository into your FiftyOne plugins directory:
cd /path/to/fiftyone-plugins
ln -s "$(pwd)" "$(fiftyone config plugins_dir)/voxelgpt"
- Follow these instructions to install Fiftyone from source
- Checkout contribution guide for Fiftyone project
- Set the
FIFTYONE_DIR
environment variable to the location where you cloned thefiftyone
repository
- Run
yarn install
- Run
yarn create-plugin <your-plugin-name>
to create a new plugin
- Run
bash install.bash
to install the dev dependencies
- Run
yarn workspace <plugin-name> dev
to compile/watch a plugin
To build a plugin with JavaScript assets (i.e. Panel, Operators, etc.) outside
of this repository, some additional configuration is required. Take a look at
voxelgpt plugin
repository for an example of configurations required for JavaScript build
externally. Mainly, your vite.config.js
will need to be similar to
vite.config.js
of
voxelgpt
plugin. Additionally, you will need to install the dependencies listed in
vite.config.js
(i.e. vite
, @vitejs/plugin-react
,
@rollup/plugin-node-resolve
, vite-plugin-externals
, etc.) as a
dev-dependencies for your JavaScript plugin project.