Files
archived-tauri-docs/docs/usage/patterns/cloudbridge.md
Laegel 441fc32f34 Feat/moving website content (#48)
* chore: moving files from 'website' folder

* chore(readme): Removed 'cd website' line

* chore: Moving netlify.toml

* chore(conflicts)
2020-05-25 23:43:14 +02:00

2.2 KiB

id, title, sidebar_label
id title sidebar_label
cloudbridge Cloudbridge Cloudbridge

import Rater from '@theme/Rater'

Ease of Use
Extensibility
Performance
Security
Cloudbridge
Pros:
  • All available features
  • No Rust skills required
Cons:
  • Largest bundle size
  • Hard to separate concerns

Description

The Cloudbridge recipe combines the flexibility of a localhost and the security of the bridge. With so many features, it can be easy to get lost.

Diagram

import Mermaid, { colors } from '@theme/Mermaid'

<Mermaid chart={graph TD H==>F2 H==>D2 D2-->F2 F2-->D2 B-->D D-->B E2-->D D-->E2 subgraph WEBVIEW F2 E2 end subgraph SERVER D2 E-->D2 end subgraph RUST A==>H A-->B B-.-C end A[Binary] B{Rust Broker} C[Subprocess] D(( API BRIDGE )) E{JS Broker} D2(( localhost )) E[bundled resources] E2{JS Broker} F2[Window] H{Bootstrap} style D fill:#ccc,stroke:#333,stroke-width:4px,color:white style RUST fill:${colors.orange.light},stroke:${colors.orange.dark},stroke-width:4px style WEBVIEW fill:${colors.blue.light},stroke:${colors.blue.dark},stroke-width:4px style SERVER fill:#49A24A,stroke:#2B6063,stroke-width:4px } />

Configuration

Here's what you need to add to your tauri.conf.json file:

"tauri": {
  "embeddedServer": {
    "active": true                // ship with a localhost server
  },
  "whitelist": {
    "all": true                   // enable entire API
  }
}