Commit 2f1d97a
Recipes for GA (#41)
* feat: add multi-framework recipes IA, MFE recipes, and embedding scaffolding
Reposition the React Recipes site as Multi-Framework Recipes per
docs/multi-framework-recipes-ui-plan.md.
- Registry: recipes now carry flavors[] (hosting × framework) with
resolveFlavor / hasFlavor / listRecipes helpers.
- Navbar: rebrand to Multi-Framework Recipes, add framework switcher
(Vue/Angular disabled "(soon)", persisted to localStorage).
- Home: hosting radio filter, Hosting Models explainer, footer link
to the (placeholder) advanced server-recipes repo.
- Standard category pages: hosting/framework chip next to the header.
- Embedding (MFE): URL-driven flavor switcher (host/fw params),
contextual server-repo callout when externally-hosted, all unbuilt
flavors visible as disabled "(soon)" tabs.
- Search: index hosting/framework keywords + category name; result
rows show flavor chips.
- mfe-app/: standalone Vite app (Externally-Hosted React guests).
- force-app/main/default/lwc/: lwc-shell host components for the
seven MFE recipes (basic embed, receive data, send event,
auto-resize, theme tokens, dirty state, GraphQL bridge) plus a
vendor lwc-shell shim and the Localhost CSP trusted site.
Verified: tsc -b, eslint, vitest 233/233.
* planning doc removed
* feat(embedding): migrate to Platform SDK + <lightning-embedding>
Replaces the legacy @salesforce/experimental-mfe-bridge / vendored
<lwc-shell> stack with the GA-track @salesforce/platform-sdk and the
<lightning-embedding> base component, matching the lo2demo-sfdx
react-sdk pattern.
Guest (mfe-app):
- Switch dependency from @salesforce/experimental-mfe-bridge to
@salesforce/platform-sdk@10.9.2; add side-effect import
@salesforce/platform-sdk/sf-embedding in main.tsx
- Add SdkProvider context + useSdk() hook; resolve chat/view SDKs
once at startup via top-level await Promise.all
- Rewrite all six recipes against the SDK surface:
- BasicEmbed: chat.getHostContext()
- ReceiveData: view.getUiProps() + URLSearchParams fallback
- SendEvent: view.dispatchEvent(name, data)
- AutoResize: view.resize() driven by ResizeObserver
- ThemeTokens: view.getTheme() + chat.getHostContext()
- DirtyState: view.markDirtyState() / clearDirtyState()
- Drop GraphQLBridge recipe (host-side bridge.graphql() retired)
Host (LWC):
- Replace each mfe* host with a declarative <lightning-embedding>
wrapper; drop imperative document.createElement('lwc-shell') and
c/vendorLwcShell imports
- Delete vendored vendorLwcShell (no longer needed; <lightning-embedding>
is provided by the platform)
- Delete mfeGraphQL host
Explorer / docs:
- Rename Embedding route /mfe -> /embedding
- Update Mfe.tsx, recipeRegistry, READMEs, CSP description, and Home
page copy to reflect the SDK-shaped recipes
* build(deps): bump @salesforce/platform-sdk, ui-bundle, and vite-plugin-ui-bundle to ^10.24.0 (#40)
* updated ga recipes
* fix(mfe): align recipes with sf-embedding-bridge channels
- ReceiveData: host publishes via props binding; guest reads getUiState (drop URL query-param remount)
- ThemeTokens: publish tokens on both style variables and props channels for base-component version resilience; guest prefers styles.variables, falls back to props
- AutoResize: rely on bootstrap's auto-attached EmbeddingResizer; remove fixed-height cap so iframe grows with content
- bump @salesforce/platform-sdk to ^11.27.0
- ignore *.tsbuildinfo
* mfe-app moved under react-recipes
* build(deps): bump websocket-driver
Bumps [websocket-driver](https://github.com/faye/websocket-driver-node) from 0.7.4 to 0.7.5.
- [Changelog](https://github.com/faye/websocket-driver-node/blob/main/CHANGELOG.md)
- [Commits](faye/websocket-driver-node@0.7.4...0.7.5)
---
updated-dependencies:
- dependency-name: websocket-driver
dependency-version: 0.7.5
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <support@github.com>
* refactor(mfe): rename lightning-embedding to lightning-ui-embedding
* chore(mfe): drop lwc-shell/mfe-app scaffolding from #39, keep lightning-embedding architecture
---------
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Charles Watkins <168678941+charlesw-salesforce@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>1 parent 048a30b commit 2f1d97a
112 files changed
Lines changed: 2014 additions & 4041 deletions
File tree
- force-app/main
- default
- cspTrustedSites
- lwc
- mfeAutoResize
- mfeBasicEmbed
- mfeDirtyState
- mfeReceiveData
- mfeSendEvent
- mfeThemeTokens
- vendorLwcShell
- react-recipes/uiBundles/reactRecipes
- src
- api
- mfe
- recipes
- pages
- recipes
- error-handling
- hello
- integration
- modify-data
- read-data
- routing
- salesforce-apis
- styles
- mfe-app
- src
- recipes
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
15 | 21 | | |
16 | 22 | | |
17 | 23 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | | - | |
| 43 | + | |
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
47 | | - | |
| 47 | + | |
48 | 48 | | |
49 | 49 | | |
50 | | - | |
51 | | - | |
| 50 | + | |
52 | 51 | | |
53 | 52 | | |
54 | 53 | | |
55 | 54 | | |
56 | | - | |
| 55 | + | |
57 | 56 | | |
58 | | - | |
| 57 | + | |
59 | 58 | | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
| 59 | + | |
64 | 60 | | |
65 | 61 | | |
66 | 62 | | |
| |||
244 | 240 | | |
245 | 241 | | |
246 | 242 | | |
247 | | - | |
| 243 | + | |
248 | 244 | | |
249 | | - | |
| 245 | + | |
250 | 246 | | |
251 | | - | |
| 247 | + | |
252 | 248 | | |
253 | 249 | | |
254 | | - | |
| 250 | + | |
255 | 251 | | |
256 | | - | |
257 | | - | |
258 | | - | |
259 | | - | |
260 | | - | |
261 | 252 | | |
262 | 253 | | |
263 | 254 | | |
264 | | - | |
| 255 | + | |
265 | 256 | | |
266 | 257 | | |
267 | 258 | | |
268 | 259 | | |
269 | | - | |
270 | | - | |
271 | | - | |
272 | | - | |
273 | | - | |
274 | | - | |
275 | | - | |
276 | | - | |
277 | | - | |
278 | | - | |
| 260 | + | |
| 261 | + | |
279 | 262 | | |
280 | 263 | | |
281 | | - | |
| 264 | + | |
282 | 265 | | |
283 | 266 | | |
284 | 267 | | |
285 | | - | |
| 268 | + | |
286 | 269 | | |
287 | | - | |
288 | | - | |
289 | | - | |
290 | | - | |
291 | | - | |
292 | | - | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
293 | 276 | | |
294 | 277 | | |
295 | 278 | | |
296 | | - | |
| 279 | + | |
297 | 280 | | |
298 | 281 | | |
299 | 282 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
7 | | - | |
| 6 | + | |
| 7 | + | |
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| |||
Lines changed: 10 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
Lines changed: 14 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
6 | | - | |
7 | | - | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
8 | 10 | | |
9 | | - | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
10 | 20 | | |
11 | 21 | | |
12 | 22 | | |
Lines changed: 3 additions & 37 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
3 | 2 | | |
4 | 3 | | |
5 | | - | |
6 | | - | |
| 4 | + | |
| 5 | + | |
7 | 6 | | |
8 | 7 | | |
9 | 8 | | |
10 | | - | |
| 9 | + | |
11 | 10 | | |
12 | 11 | | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | 12 | | |
Lines changed: 10 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
6 | | - | |
| 5 | + | |
| 6 | + | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
9 | 16 | | |
10 | 17 | | |
11 | 18 | | |
Lines changed: 3 additions & 32 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
3 | 2 | | |
4 | 3 | | |
5 | | - | |
6 | | - | |
| 4 | + | |
| 5 | + | |
7 | 6 | | |
8 | 7 | | |
9 | 8 | | |
10 | | - | |
| 9 | + | |
11 | 10 | | |
12 | 11 | | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | 12 | | |
Lines changed: 24 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | | - | |
6 | | - | |
7 | | - | |
8 | | - | |
9 | | - | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
10 | 10 | | |
11 | | - | |
12 | | - | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
13 | 29 | | |
14 | | - | |
15 | 30 | | |
16 | 31 | | |
17 | 32 | | |
0 commit comments