diff --git a/README.md b/README.md index 108b425..5b3e1dc 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ Run figwheel using `clojure -A:figwheel`. Documentation website is maintained using [docusaurus](https://docusaurus.io). The layout logic can be found in `website` while the content is kept in `docs`. -To hack on the documentation, run `npm run start`. +To hack on the documentation, run `npm run start` in `website` folder. ### IPFS diff --git a/docs/Roadmap.md b/docs/Roadmap.md new file mode 100644 index 0000000..9b94589 --- /dev/null +++ b/docs/Roadmap.md @@ -0,0 +1,56 @@ +Extensions development is currently in progress + +## Done + +### Pre-MVP + +Validate technical feasibility. + +* general mechanism (UI, conditionals, queries, events) +* HTML based +* stored in ipfs (via gateway) +* no concept of hooks +* no custom code +* extension are activated when loaded and cannot be deactivated + +### MVP + +Pre-MVP integrated in Status. + +## In progress + +### Iteration 1 + +Migrate old commands to extensions. + +* implement hooks and proposed extension points _DONE_ +* registry and hooks API _DONE_ +* define extensions points for status _DONE_ +* implement i18n [#10](https://github.com/status-im/pluto/issues/10) +* query and events API (data can be passed around) [#9](https://github.com/status-im/pluto/issues/9) and [#8](https://github.com/status-im/pluto/issues/8) +* implement destructuring [#28](https://github.com/status-im/pluto/issues/28) +* isolated data per extension [#29](https://github.com/status-im/pluto/issues/29) + +## Next + +### Iteration 2 + +Add custom code support. + +* implement security mechanism / permissions +* remote code loading +* JavaScript API + +### Iteration 3 + +Persistent extensions. + +* implement data persistence +* add extension registry UI + +### Iteration 4 + +Support dependencies. + +* add versioning support +* extensions can depend on others extensions diff --git a/docs/concepts/Anatomy.md b/docs/concepts/Anatomy.md new file mode 100644 index 0000000..92ab1d4 --- /dev/null +++ b/docs/concepts/Anatomy.md @@ -0,0 +1,18 @@ +--- +sidebar_label: Anatomy +--- + +A host defines a number of [hooks](Hook) in various parts of the app. Those hooks are contracts that 3rd party devs can +use to extend a host with their own logic / UI. +e.g. custom chat commands, custom chat actions, custom collectible displays. + +An `extension` is provided by 3rd party developers and provides one or multiple hooks implementation. + +To implement a hook, a 3rd party devs has access to some APIs: +* `view` to create native UI (e.g. text, list) +* `query` to access host data (e.g contacts, whisper key) +* `event` to modify host state (e.g. create a contact, scan a QR code, send a chat message) + +Extensions are stored in IPFS or SWARM. They can be identified using ENS names. + +A user can discover extensions and decide to install them. Once installed associated hooks become active and modify the host. diff --git a/docs/format/Hook.md b/docs/concepts/Hook.md similarity index 88% rename from docs/format/Hook.md rename to docs/concepts/Hook.md index cc31d50..18df08e 100644 --- a/docs/format/Hook.md +++ b/docs/concepts/Hook.md @@ -1,10 +1,11 @@ --- +title: Hook sidebar_label: Hook --- Hook is the mechanism allowing a specific extensions host to define what (and how) can be extended. -Hooks are defined as part of capacities by maps detailing properties and their associated type. They leverage [references](/reference) to use various extensions elements. +Hooks are defined as part of capacities by maps detailing properties and their associated type. They leverage [references](Reference) to use various extensions elements. ```clojure {:capacities {hooks/main {:properties [{:name :view :type :view} {:name :name :type :string}]}}} diff --git a/docs/format/Reference.md b/docs/concepts/Reference.md similarity index 100% rename from docs/format/Reference.md rename to docs/concepts/Reference.md diff --git a/docs/format/Registry.md b/docs/concepts/Registry.md similarity index 100% rename from docs/format/Registry.md rename to docs/concepts/Registry.md diff --git a/docs/format/Type.md b/docs/concepts/Type.md similarity index 100% rename from docs/format/Type.md rename to docs/concepts/Type.md diff --git a/docs/format/View.md b/docs/concepts/View.md similarity index 100% rename from docs/format/View.md rename to docs/concepts/View.md diff --git a/docs/index.html b/docs/index.html deleted file mode 100644 index 4443070..0000000 --- a/docs/index.html +++ /dev/null @@ -1,54 +0,0 @@ - -
- - - - -