diff --git a/docs/module1/_category_.json b/docs/module1/_category_.json index 5b002d4..0179b4b 100644 --- a/docs/module1/_category_.json +++ b/docs/module1/_category_.json @@ -1,8 +1,4 @@ { - "label": "Module1", - "position": 2, - "link": { - "type": "generated-index", - "description": "5 minutes to learn the most important Docusaurus concepts." - } + "label": "plasmo介绍 & 环境准备", + "position": 2 } diff --git a/docs/module1/basic_react.mdx b/docs/module1/basic_react.mdx new file mode 100644 index 0000000..1c20d1e --- /dev/null +++ b/docs/module1/basic_react.mdx @@ -0,0 +1,5 @@ +--- +sidebar_position: 4 +--- + +# React 基础 diff --git a/docs/module1/index.mdx b/docs/module1/index.mdx deleted file mode 100644 index a7c911b..0000000 --- a/docs/module1/index.mdx +++ /dev/null @@ -1,151 +0,0 @@ ---- -sidebar_position: 4 ---- - -# Markdown Features - -Docusaurus supports **[Markdown](https://daringfireball.net/projects/markdown/syntax)** and a few **additional features**. - -## Front Matter - -Markdown documents have metadata at the top called [Front Matter](https://jekyllrb.com/docs/front-matter/): - -```text title="my-doc.md" -// highlight-start ---- -id: my-doc-id -title: My document title -description: My document description -slug: /my-custom-url ---- -// highlight-end - -## Markdown heading - -Markdown text with [links](./hello.md) -``` - -## Links - -Regular Markdown links are supported, using url paths or relative file paths. - -```md -Let's see how to [Create a page](/create-a-page). -``` - -```md -Let's see how to [Create a page](./second.md). -``` - -**Result:** Let's see how to [Create a page](./second.md). - -## Images - -Regular Markdown images are supported. - -You can use absolute paths to reference images in the static directory (`static/img/docusaurus.png`): - -```md -![Docusaurus logo](/img/docusaurus.png) -``` - -![Docusaurus logo](/img/docusaurus.png) - -You can reference images relative to the current file as well. This is particularly useful to colocate images close to the Markdown files using them: - -```md -![Docusaurus logo](./img/docusaurus.png) -``` - -## Code Blocks - -Markdown code blocks are supported with Syntax highlighting. - - ```jsx title="src/components/HelloDocusaurus.js" - function HelloDocusaurus() { - return ( -

Hello, Docusaurus!

- ) - } - ``` - -```jsx title="src/components/HelloDocusaurus.js" -function HelloDocusaurus() { - return

Hello, Docusaurus!

; -} -``` - -## Admonitions - -Docusaurus has a special syntax to create admonitions and callouts: - - :::tip My tip - - Use this awesome feature option - - ::: - - :::danger Take care - - This action is dangerous - - ::: - -:::tip My tip - -Use this awesome feature option - -::: - -:::danger Take care - -This action is dangerous - -::: - -## MDX and React Components - -[MDX](https://mdxjs.com/) can make your documentation more **interactive** and allows using any **React components inside Markdown**: - -```jsx -export const Highlight = ({children, color}) => ( - { - alert(`You clicked the color ${color} with label ${children}`) - }}> - {children} - -); - -This is Docusaurus green ! - -This is Facebook blue ! -``` - -export const Highlight = ({ children, color }) => ( - { - alert(`You clicked the color ${color} with label ${children}`); - }} - > - {children} - -); - -This is Docusaurus green ! - -This is Facebook blue ! diff --git a/docs/module1/introduction.mdx b/docs/module1/introduction.mdx new file mode 100644 index 0000000..6e07a4a --- /dev/null +++ b/docs/module1/introduction.mdx @@ -0,0 +1,5 @@ +--- +sidebar_position: 3 +--- + +# plasmo 介绍 diff --git a/docs/module1/readme.mdx b/docs/module1/readme.mdx new file mode 100644 index 0000000..6e74bbe --- /dev/null +++ b/docs/module1/readme.mdx @@ -0,0 +1 @@ +# 模块介绍 \ No newline at end of file diff --git a/docs/module1/second.md b/docs/module1/second.md deleted file mode 100644 index e69de29..0000000 diff --git a/docs/module2/_category_.json b/docs/module2/_category_.json index 62aef45..3d9e930 100644 --- a/docs/module2/_category_.json +++ b/docs/module2/_category_.json @@ -1,8 +1,4 @@ { - "label": "Module2", - "position": 3, - "link": { - "type": "generated-index", - "description": "5 minutes to learn the most important Docusaurus concepts." - } + "label": "Plasmo Pages ", + "position": 3 } diff --git a/docs/module2/assets.mdx b/docs/module2/assets.mdx new file mode 100644 index 0000000..0f39d4c --- /dev/null +++ b/docs/module2/assets.mdx @@ -0,0 +1,9 @@ +--- +sidebar_position: 5 +--- + +# 静态资源使用 + +## 资源 + +## 图标 (icon) diff --git a/docs/module2/index.mdx b/docs/module2/index.mdx index a7c911b..d0340a8 100644 --- a/docs/module2/index.mdx +++ b/docs/module2/index.mdx @@ -1,7 +1,3 @@ ---- -sidebar_position: 4 ---- - # Markdown Features Docusaurus supports **[Markdown](https://daringfireball.net/projects/markdown/syntax)** and a few **additional features**. diff --git a/docs/module2/pages.mdx b/docs/module2/pages.mdx new file mode 100644 index 0000000..e4fc45d --- /dev/null +++ b/docs/module2/pages.mdx @@ -0,0 +1,11 @@ +--- +sidebar_position: 4 +--- + +# Pages + +## extension pages + +## tab pages + +## sandbox pages diff --git a/docs/module2/second.md b/docs/module2/second.md deleted file mode 100644 index e69de29..0000000 diff --git a/docs/module2/workflow.mdx b/docs/module2/workflow.mdx new file mode 100644 index 0000000..d28d496 --- /dev/null +++ b/docs/module2/workflow.mdx @@ -0,0 +1,5 @@ +--- +sidebar_position: 3 +--- + +# 开发工作流 diff --git a/docs/module3/_category_.json b/docs/module3/_category_.json index ab195db..9545474 100644 --- a/docs/module3/_category_.json +++ b/docs/module3/_category_.json @@ -1,8 +1,4 @@ { - "label": "Module3", - "position": 4, - "link": { - "type": "generated-index", - "description": "5 minutes to learn the most important Docusaurus concepts." - } + "label": "Content Script (UI)", + "position": 4 } diff --git a/docs/module3/content.mdx b/docs/module3/content.mdx new file mode 100644 index 0000000..e8246b9 --- /dev/null +++ b/docs/module3/content.mdx @@ -0,0 +1,5 @@ +--- +sidebar_position: 4 +--- + +# Content Script \ No newline at end of file diff --git a/docs/module3/contentui.mdx b/docs/module3/contentui.mdx new file mode 100644 index 0000000..d2d573f --- /dev/null +++ b/docs/module3/contentui.mdx @@ -0,0 +1,5 @@ +--- +sidebar_position: 4 +--- + +# Content Script UI \ No newline at end of file diff --git a/docs/module3/index.mdx b/docs/module3/index.mdx index a7c911b..d0340a8 100644 --- a/docs/module3/index.mdx +++ b/docs/module3/index.mdx @@ -1,7 +1,3 @@ ---- -sidebar_position: 4 ---- - # Markdown Features Docusaurus supports **[Markdown](https://daringfireball.net/projects/markdown/syntax)** and a few **additional features**. diff --git a/docs/module3/second.md b/docs/module3/second.md deleted file mode 100644 index e69de29..0000000 diff --git a/docs/module4/_category_.json b/docs/module4/_category_.json index 7f874bb..99dd7b3 100644 --- a/docs/module4/_category_.json +++ b/docs/module4/_category_.json @@ -1,8 +1,4 @@ { - "label": "Module4", - "position": 5, - "link": { - "type": "generated-index", - "description": "5 minutes to learn the most important Docusaurus concepts." - } + "label": "外部通信", + "position": 5 } diff --git a/docs/module4/backgroundws.mdx b/docs/module4/backgroundws.mdx new file mode 100644 index 0000000..c8ead9e --- /dev/null +++ b/docs/module4/backgroundws.mdx @@ -0,0 +1,5 @@ +--- +sidebar_position: 4 +--- + +# Background Service Worker \ No newline at end of file diff --git a/docs/module4/message.mdx b/docs/module4/message.mdx new file mode 100644 index 0000000..a160e41 --- /dev/null +++ b/docs/module4/message.mdx @@ -0,0 +1,5 @@ +--- +sidebar_position: 4 +--- + +# Message API diff --git a/docs/module4/remote.mdx b/docs/module4/remote.mdx new file mode 100644 index 0000000..7e2aa9a --- /dev/null +++ b/docs/module4/remote.mdx @@ -0,0 +1,5 @@ +--- +sidebar_position: 5 +--- + +# Remote Code diff --git a/docs/module4/second.md b/docs/module4/second.md deleted file mode 100644 index e69de29..0000000 diff --git a/docs/module4/storage.mdx b/docs/module4/storage.mdx new file mode 100644 index 0000000..d90a8bb --- /dev/null +++ b/docs/module4/storage.mdx @@ -0,0 +1,5 @@ +--- +sidebar_position: 5 +--- + +# Storage