diff --git a/README.md b/README.md index 0bafe66..3fce604 100644 --- a/README.md +++ b/README.md @@ -11,6 +11,7 @@ Pulse Editor
+[![Static Badge](https://img.shields.io/badge/docs-8A2BE2?style=for-the-badge)](https://docs.pulse-editor.com) [![Discord](https://img.shields.io/badge/Discord-%235865F2.svg?style=for-the-badge&logo=discord&logoColor=white)](https://discord.gg/s6J54HFxQp) [![Licence](https://img.shields.io/github/license/Ileriayo/markdown-badges?style=for-the-badge)](./LICENSE) diff --git a/docs/docs/guide/develop-extensions/_category_.json b/docs/docs/guide/develop-extensions/_category_.json deleted file mode 100644 index 20a6579..0000000 --- a/docs/docs/guide/develop-extensions/_category_.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "label": "Development Guide", - "position": 6 -} \ No newline at end of file diff --git a/docs/docs/guide/develop-extensions/index.md b/docs/docs/guide/develop-extensions/index.md index 768a3af..70e66d6 100644 --- a/docs/docs/guide/develop-extensions/index.md +++ b/docs/docs/guide/develop-extensions/index.md @@ -1,4 +1,8 @@ -# Develop Extensions +--- +sidebar_position: 5 +--- + +# Development Guide ## Choose your framework diff --git a/docs/docs/guide/develop-extensions/react.md b/docs/docs/guide/develop-extensions/react.md new file mode 100644 index 0000000..797c849 --- /dev/null +++ b/docs/docs/guide/develop-extensions/react.md @@ -0,0 +1,11 @@ +# Develop Extensions with React + +## Create an extension project with React +```bash +pulse create --framework react +``` + +## React Library +The `@pulse-editor/react-api` is automatically installed if you create a project using the command above. + +In this package, it provides many useful hooks for your extension to interact with Pulse Editor Core via [Inter-Module Communication (IMC)](/docs/guide/pulse-editor-app/extension-system/imc). \ No newline at end of file diff --git a/docs/docs/guide/develop-extensions/react/_category_.json b/docs/docs/guide/develop-extensions/react/_category_.json deleted file mode 100644 index ef302b8..0000000 --- a/docs/docs/guide/develop-extensions/react/_category_.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "label": "Develop Extensions with React", - "position": 2 -} \ No newline at end of file diff --git a/docs/docs/guide/develop-extensions/react/index.md b/docs/docs/guide/develop-extensions/react/index.md deleted file mode 100644 index 90dcc5f..0000000 --- a/docs/docs/guide/develop-extensions/react/index.md +++ /dev/null @@ -1 +0,0 @@ -# React \ No newline at end of file diff --git a/docs/docs/guide/develop-extensions/react/react-template.md b/docs/docs/guide/develop-extensions/react/react-template.md deleted file mode 100644 index 31a87e8..0000000 --- a/docs/docs/guide/develop-extensions/react/react-template.md +++ /dev/null @@ -1 +0,0 @@ -# React Starter Template \ No newline at end of file diff --git a/docs/docs/guide/pulse-editor-app/_category_.json b/docs/docs/guide/pulse-editor-app/_category_.json deleted file mode 100644 index 3b792ab..0000000 --- a/docs/docs/guide/pulse-editor-app/_category_.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "label": "Pulse Editor App", - "position": 4 -} diff --git a/docs/docs/guide/pulse-editor-app/concepts.md b/docs/docs/guide/pulse-editor-app/concepts.md index 74d42e1..c096522 100644 --- a/docs/docs/guide/pulse-editor-app/concepts.md +++ b/docs/docs/guide/pulse-editor-app/concepts.md @@ -1 +1,5 @@ +--- +sidebar_position: 1 +--- + # Concepts diff --git a/docs/docs/guide/pulse-editor-app/extension-system/core.md b/docs/docs/guide/pulse-editor-app/extension-system/core.md new file mode 100644 index 0000000..18f432a --- /dev/null +++ b/docs/docs/guide/pulse-editor-app/extension-system/core.md @@ -0,0 +1,13 @@ +--- +sidebar_position: 1 +--- + + +# Pulse Editor Core + +## One Codebase, Every Platform +Pulse Editor Core is developed using modern web technologies with Next.js, enabling a single codebase for all platforms. Its architecture is built around abstract interfaces, allowing native-specific implementations to plug in cleanly while maintaining a consistent core logic. + +## Native Support via Electron and Capacitor +After the app is built with Next.js, it is deployed to native platforms using Electron for desktop and Capacitor for mobile. This setup enables full native functionality across devices while preserving the benefits of a unified codebase. + diff --git a/docs/docs/guide/pulse-editor-app/extension-system/extensions.md b/docs/docs/guide/pulse-editor-app/extension-system/extensions.md new file mode 100644 index 0000000..0c50548 --- /dev/null +++ b/docs/docs/guide/pulse-editor-app/extension-system/extensions.md @@ -0,0 +1,11 @@ +--- +sidebar_position: 2 +--- + +# Extensions + +Pulse Editor employs Micro-Frontend architecture with [Module Federation](https://module-federation.io/) for its modular extension system. + +Each Pulse Editor extension is a MF remote module. Pulse Editor Core registers installed extensions when Pulse Editor starts, it does not yet load at this stage. + +Pulse Editor only loads enabled extensions when either a compatible file type is opened, or a console view for that extension is opened. diff --git a/docs/docs/guide/pulse-editor-app/extension-system/imc.md b/docs/docs/guide/pulse-editor-app/extension-system/imc.md new file mode 100644 index 0000000..5f64a0a --- /dev/null +++ b/docs/docs/guide/pulse-editor-app/extension-system/imc.md @@ -0,0 +1,20 @@ +--- +sidebar_position: 3 +--- + +# Inter-Module Communication (IMC) + + +**Inter-Module Communication (IMC)** provides communication channels between different modules powered by Webpack Module Federation. Essentially, this means every module (extensions and Pulse Editor Core) is able to establish incoming and outgoing channels with any other modules (extensions and Pulse Editor Core). + +:::info +Establishing **IMC** between extensions is up to the extensions' developer(s). Pulse Editor does **not** make communication channels **among extensions** by default, it **only** establishes communication channels between **itself (Pulse Editor Core)** and **any extension** upon loading that extension. + +For example: +When extension A and B load, the Core makes IMC connections like so: +**Core < -- > Extension A** +**Core < -- > Extension B** + +But Pulse Editor does not make the following connection, unless the developer of extension A and developer of extension B agree to inter-connect them with utils from `@pulse-editor/shared-utils`: +**Extension A < -- > Extension B** +::: \ No newline at end of file diff --git a/docs/docs/guide/pulse-editor-app/extension-system/index.md b/docs/docs/guide/pulse-editor-app/extension-system/index.md index fad7923..bcdac22 100644 --- a/docs/docs/guide/pulse-editor-app/extension-system/index.md +++ b/docs/docs/guide/pulse-editor-app/extension-system/index.md @@ -1 +1,11 @@ -# Extension System \ No newline at end of file +--- +sidebar_position: 2 +--- + +# Extension System + +Pulse Editor is built upon powerful Micro-Frontend technologies to be modular, extensible, and cross-platform. + +import DocCardList from '@theme/DocCardList'; + + diff --git a/docs/docs/guide/pulse-editor-app/index.md b/docs/docs/guide/pulse-editor-app/index.md index 9f92fdc..a92a9c6 100644 --- a/docs/docs/guide/pulse-editor-app/index.md +++ b/docs/docs/guide/pulse-editor-app/index.md @@ -1,3 +1,7 @@ +--- +sidebar_position: 4 +--- + # Pulse Editor App ## Learn about core concepts of Pulse Editor App