Skip to content

Commit e9c57eb

Browse files
committed
Improved docs
1 parent a411ce0 commit e9c57eb

File tree

5 files changed

+27
-5
lines changed

5 files changed

+27
-5
lines changed

.vitepress/config.mts

+1-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ export default defineConfig({
4343

4444
footer: {
4545
message: "Released under the MIT License.",
46-
copyright: "Copyright © 2024-present smapiot",
46+
copyright: "Copyright © 2024-present smapiot GmbH",
4747
},
4848

4949
nav: [

guide/features.md

+14
Original file line numberDiff line numberDiff line change
@@ -8,28 +8,40 @@ Picard.js is your comprehensive solution for orchestrating micro frontends, prov
88

99
Picard.js is designed to be versatile and adaptable across various environments. Whether you're working in a browser, Node.js, Deno, or Electron, Picard.js seamlessly orchestrates micro frontends, ensuring consistent performance and compatibility.
1010

11+
:point_right: Want to see this in action? [Example online](https://github.com/picardjs/picard/blob/develop/examples/08-ssr-tractor/package.json)
12+
1113
## Multi Format
1214

1315
With Picard.js, you can integrate and manage multiple micro frontend formats effortlessly. It supports Module Federation, Native Federation, Pilets, and more, providing flexibility and ease of use for diverse development needs.
1416

17+
:point_right: Want to see this in action? [Example online](https://github.com/picardjs/picard/blob/main/examples/10-dependencies-sharing/index.html)
18+
1519
## Multi Framework
1620

1721
![Multi Framework](../images/multi-framework.svg)
1822

1923
Picard.js excels at integrating various frameworks, including single-spa, HTML fragments, and web components. This multi-framework support allows you to choose the best tools for each part of your application, fostering innovation and efficiency.
2024

25+
:point_right: Want to see this in action? [Example online](https://github.com/picardjs/picard/blob/develop/examples/06-static-page-single-spa/index.html)
26+
2127
## Error Handling
2228

2329
Picard.js takes the hassle out of managing errors. It automatically handles errors across your micro frontends, ensuring a smooth and uninterrupted user experience while reducing the need for manual error management.
2430

31+
:point_right: Want to see this in action? [Example online](https://github.com/picardjs/picard/blob/main/examples/06-static-page-single-spa/mfs/red/src/Product.jsx#L87)
32+
2533
## Loose and Strong Coupling
2634

2735
Picard.js supports both loose and strong coupling of micro frontends. Utilize a micro frontend discovery service for loose coupling or specify script URLs directly for strong coupling, akin to module federation, allowing you to tailor the integration to your specific requirements.
2836

37+
:point_right: Want to see this in action? [Example online](https://github.com/picardjs/picard/blob/develop/examples/02-static-page-feed/index.html#L10)
38+
2939
## Optional Routing
3040

3141
Picard.js provides robust routing capabilities, whether you need client-side or server-side routing. This flexibility enables you to design your application's navigation in the most efficient and effective way possible.
3242

43+
:point_right: Want to see this in action? [Example online](https://github.com/picardjs/picard/blob/develop/examples/05-static-page-with-routing/index.html#L11)
44+
3345
## Debugging
3446

3547
Debugging with Picard.js is straightforward and integrates seamlessly into your existing development workflows. It supports native debugging processes and extends compatibility with micro frontend debugging utilities such as the [Piral Inspector](https://github.com/smapiot/piral-inspector), enhancing your ability to identify and resolve issues quickly.
@@ -39,3 +51,5 @@ Debugging with Picard.js is straightforward and integrates seamlessly into your
3951
![Islands Architecture](../images/islands-architecture.svg)
4052

4153
Picard.js facilitates the creation of island architectures, enabling server-side rendered (SSR) applications that can hydrate and continue on the client side. This approach optimizes performance and user experience, combining the best of SSR and client-side rendering.
54+
55+
:point_right: Want to see this in action? [Example online](https://github.com/picardjs/picard/blob/develop/examples/09-islands-netflix/package.json)

guide/variants/browser.md

+8
Original file line numberDiff line numberDiff line change
@@ -62,3 +62,11 @@ When Picard.js starts it will look for a script tag with the `type` set to `pi-s
6262
```
6363

6464
The provided state must match the format of Picard's internal state. One way to get this is to retrieve an export of the internal state, e.g., using the `readState()` function on `window.picard`.
65+
66+
::: warning
67+
The provided state is not type-checked. As a result, any wrong or unexpected input here might lead to some undefined behavior later on.
68+
69+
Always just take the state as it was exported via `JSON.stringify(picard.readState())` as input for a `pi-state` script.
70+
:::
71+
72+
Ideally, you don't use this thing directly, but rely on Picard.js doing it implicitly, e.g., when using SSR with an islands architecture model.

guide/why.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ One of the reasons why Picard.js might be interesting for you is that it allows
1414

1515
For owners of existing micro frontend solutions the integration of other micro frontends will no longer break due to technology incompatibilities. If two micro frontends have been written - one using Module Federation and another one using Native Federation - you will no longer require some frankenstein solution, but instead can just embed both; and it will just work.
1616

17-
👉 Want to see this in action? [Example online](https://github.com/picardjs/picard/blob/main/examples/10-dependencies-sharing/index.html)
17+
:point_right: Want to see this in action? [Example online](https://github.com/picardjs/picard/blob/main/examples/10-dependencies-sharing/index.html)
1818

1919
### Error Handling
2020

@@ -24,7 +24,7 @@ Error handling has been one of the largest problems in solutions like Module Fed
2424

2525
With Picard.js error handling is integrated from the ground up. You reference an invalid component? Nothing bad will happen. The component crashes or does not accept the given inputs? The solution will just continue - if you care you can pick up the error and display something else instead.
2626

27-
👉 Want to see this in action? [Example online](https://github.com/picardjs/picard/blob/main/examples/06-static-page-single-spa/mfs/red/src/Product.jsx#L87)
27+
:point_right: Want to see this in action? [Example online](https://github.com/picardjs/picard/blob/main/examples/06-static-page-single-spa/mfs/red/src/Product.jsx#L87)
2828

2929
### Technology Agnostic
3030

@@ -34,7 +34,7 @@ A design goal of Picard.js was to work without any tooling. As such owners of ex
3434

3535
One advantage of this approach is that - out-of-the-box - Picard.js is technology agnostic. While other approaches require specific tooling to work we don't need this here. As a result, Picard.js can also be used with tooling that is rather micro frontend hostile such as the Angular CLI. As long as there is some HTML somewhere you can add the script and use the web components.
3636

37-
👉 Want to see this in action? [Example online](https://github.com/picardjs/picard/blob/main/examples/01-static-page/index.html)
37+
:point_right: Want to see this in action? [Example online](https://github.com/picardjs/picard/blob/main/examples/01-static-page/index.html)
3838

3939
## Why use a Library as Orchestrator?
4040

index.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ features:
2929
details: Just works with micro frontends using single-spa, Piral, Module Federation, and Native Federation.
3030
---
3131

32-
<style>
32+
<style is:global>
3333
:root {
3434
--vp-home-hero-name-color: transparent;
3535
--vp-home-hero-name-background: linear-gradient(120deg, #ff007f 30%, #41d1ff);

0 commit comments

Comments
 (0)