From d307e97fa27e041198036bfd676f0a97d7ba4c41 Mon Sep 17 00:00:00 2001 From: Xi Yan Date: Tue, 29 Oct 2024 17:08:01 -0700 Subject: [PATCH] test tabs --- docs/requirements.txt | 1 + docs/source/conf.py | 2 +- docs/source/getting_started/index.md | 13 +++++++++++++ 3 files changed, 15 insertions(+), 1 deletion(-) diff --git a/docs/requirements.txt b/docs/requirements.txt index f3cc9ecb7..65a7ea61d 100644 --- a/docs/requirements.txt +++ b/docs/requirements.txt @@ -5,3 +5,4 @@ linkify sphinx-rtd-theme>=1.0.0 sphinx-pdj-theme sphinx-copybutton +sphinx-tabs diff --git a/docs/source/conf.py b/docs/source/conf.py index 0acd96f08..61db24367 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -19,7 +19,7 @@ author = "Meta" # -- General configuration --------------------------------------------------- # https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration -extensions = ["myst_parser", "sphinx_rtd_theme", "sphinx_copybutton"] +extensions = ["myst_parser", "sphinx_rtd_theme", "sphinx_copybutton", "sphinx-tabs"] html_theme = "sphinx_rtd_theme" diff --git a/docs/source/getting_started/index.md b/docs/source/getting_started/index.md index 775c11729..e5c6a196f 100644 --- a/docs/source/getting_started/index.md +++ b/docs/source/getting_started/index.md @@ -107,3 +107,16 @@ inference> Jungfraujoch, also known as the "Top of Europe," is a unique and spec User> What other countries should I consider to club? inference> Considering your interest in Switzerland, here are some neighboring countries that you may want to consider visiting: ``` + +```{tabs} +```{tab} Python +```python +def hello(): + print("Hello!") +``` +```{tab} Javascript +```javascript +function hello() { + console.log("Hello!"); +} +```