diff --git a/README.md b/README.md index eb0bae0a..a4cc6fef 100644 --- a/README.md +++ b/README.md @@ -21,6 +21,10 @@ When running the official Javy binary on Linux, `glibc` 2.31 or greater must be available. You may need to update the version of your operating system if you are using an older version of `glibc`. +## Extending Javy + +If you would like to use Javy for your own project but need to make some changes, read the [extending Javy documentation](docs/extending.md) for one approach to consider. + ## Contributing We welcome feedback, bug reports and bug fixes. We're also happy to discuss feature development but please discuss the features in an issue before contributing. diff --git a/docs/extending.md b/docs/extending.md new file mode 100644 index 00000000..dbeb483c --- /dev/null +++ b/docs/extending.md @@ -0,0 +1,3 @@ +# Extending Javy + +If you want to use Javy for your own project, you may find that the existing code is not sufficient since you may want to offer custom APIs or use different branding for the CLI. The approach we'd recommend taking is to fork and create your own version of the `javy-cli` and `javy-core` crates and depend on the upstream version of the `javy` and `javy-apis` crates. You can add your own implementations of custom JS APIs in your fork of the `javy-core` crate or in a different crate that you depend on in your `javy-core` fork. If you find that something is missing in the `javy` crate that you require to implement something in your fork, we would appreciate it if you would open a GitHub issue and consider making the change upstream instead of in your fork so all users of the `javy` crate can benefit.