INTEGRATIONS
GitHub

Custom code & code snippets with GitHub

4min

Integration with GitHub allows you to sync the Custom Code: customCSS, customJS, footerTemplate, headerTemplate, directly from the GitHub repository. These variables can be raw text or link to a file from the root folder.

You just need to define the archbee.json file in your repo and add your custom code or custom CSS, like in this example:

archbee.json
summary.md
custom.js


If you push the code to GitHub, Archbee will read the configuration from the archbee.json file and automatically update the Space Settings -> Custom Code section with your new code.

Custom code in Space settings
Custom code in Space settings


Code snippets

You can add code snippets in your GitHub repo, you just need to configure them in the config.md file.

The config.md file must be placed in the same folder as the summary.md file.

Below is an example of a config.md file:

config.md


Example

Assuming that you have the below package.json file (from the above example):

Code snippet example
Code snippet example


And also the config.md file:

config.md


You will see the following in the Archbee doc after the import:

JS




🤔
Have a question?
Our super-smart AI, knowledgeable support team and an awesome community will get you an answer in a flash.
To ask a question or participate in discussions, you'll need to authenticate first.