-
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1468 from hydephp/split-out-extensions-documentation
Split out extensions documentation
- Loading branch information
Showing
3 changed files
with
76 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
--- | ||
navigation: | ||
label: "Extensions & Integrations" | ||
groupName: "Extensions & Integrations" | ||
priority: 80 | ||
--- | ||
|
||
# Extensions & Integrations | ||
|
||
## HydePHP - Extensible by design | ||
|
||
HydePHP is designed to be extensible, and comes with a number of built-in extensions and integrations, | ||
as well as support for third-party extensions and integrations. | ||
|
||
## First party extensions & integrations | ||
|
||
### Realtime Compiler | ||
|
||
The Hyde Realtime Compiler is included with Hyde installations and is what powers the `php hyde serve` command. | ||
- Learn more about the [Realtime Compiler](realtime-compiler) in the documentation. | ||
|
||
## Integrations with third-party tools | ||
|
||
### Torchlight | ||
|
||
Torchlight is an amazing API for syntax highlighting, and is supported natively by HydePHP. | ||
- Learn more about [Torchlight](third-party-integrations#torchlight) in the documentation. | ||
|
||
## Contribute | ||
|
||
Have an idea for an extension or integration? Let me know! I'd love to hear from you. Get in touch on | ||
[GitHub](https://github.com/hydephp/hyde) or send me a DM on [Twitter](https://twitter.com/CodeWithCaen). | ||
You may also want to look at the [Extension API](extensions-api) documentation to learn how to create extensions. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
--- | ||
navigation: | ||
label: "Third-Party Integrations" | ||
priority: 85 | ||
--- | ||
|
||
# Integrations with third-party tools | ||
|
||
## Torchlight | ||
|
||
Torchlight is an amazing API for syntax highlighting, and is used by this site. I cannot recommend it highly enough, | ||
especially for documentation sites and code-heavy blogs! As such, HydePHP has built-in support for Torchlight, | ||
which is automatically enabled once you add an API token to your `.env` file. Nothing else needs to be done! | ||
|
||
### Getting started | ||
|
||
To get started you need an API token which you can get at [Torchlight.dev](https://torchlight.dev/). | ||
It is entirely free for personal and open source projects, as seen on their [pricing page](https://torchlight.dev/#pricing). | ||
|
||
When you have an API token, set it in the `.env` file in the root directory of your project. | ||
Once a token is set, Hyde will automatically enable the CommonMark extension. | ||
|
||
```env | ||
TORCHLIGHT_TOKEN=torch_<your-api-token> | ||
``` | ||
|
||
### Attribution and configuration | ||
|
||
Note that for the free plan you need to provide an attribution link. Thankfully Hyde injects a customizable link | ||
automatically to all pages that use Torchlight. You can of course disable and customize this in the `config/torchlight.php` file. | ||
|
||
```php | ||
'attribution' => [ | ||
'enabled' => true, | ||
'markdown' => 'Syntax highlighting by <a href="https://torchlight.dev/" rel="noopener nofollow">Torchlight.dev</a>', | ||
], | ||
``` | ||
|
||
Don't have this file? Run `php hyde vendor:publish` to publish it. | ||
|