@picked/client 0.0.1-dev.1789541668638 → 0.0.1-next.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -0
- package/dist/cjs/index.js +1 -4
- package/dist/cjs/plugins/create-experience/index.js +1 -1
- package/dist/cjs/plugins/experience-browserstorage-plugin/index.js +1 -0
- package/dist/cjs/plugins/history-browserstorage-plugin/index.js +1 -0
- package/dist/cjs/plugins/responses-browserstorage-plugin/index.js +1 -0
- package/dist/cjs/plugins/responses-indexeddb-plugin/index.js +1 -0
- package/dist/cjs/plugins/shopify/index.js +1 -0
- package/dist/cjs/plugins/single-page-app/index.js +1 -1
- package/dist/cjs/plugins/window-object/index.js +1 -1
- package/dist/cjs/server/index.js +1 -1
- package/dist/esm/index.js +732 -1814
- package/dist/esm/plugins/create-experience/index.js +398 -490
- package/dist/esm/plugins/experience-browserstorage-plugin/index.js +38 -0
- package/dist/esm/plugins/history-browserstorage-plugin/index.js +26 -0
- package/dist/esm/plugins/responses-browserstorage-plugin/index.js +36 -0
- package/dist/esm/plugins/responses-indexeddb-plugin/index.js +101 -0
- package/dist/esm/plugins/shopify/index.js +59 -0
- package/dist/esm/plugins/single-page-app/index.js +35 -31
- package/dist/esm/plugins/window-object/index.js +9 -9
- package/dist/esm/server/index.js +89 -141
- package/dist/experience-instance-6ZKZS7dF.cjs +1 -0
- package/dist/experience-instance-BA0EXYg5.js +712 -0
- package/dist/id-BKIWbSTy.cjs +1 -0
- package/dist/id-BW-g3y32.js +6 -0
- package/dist/logger-BsmHUUw1.cjs +1 -0
- package/dist/logger-C9a75KZn.js +5 -0
- package/dist/object-BbFTsGh3.cjs +1 -0
- package/dist/object-JwZ58NOH.js +28 -0
- package/dist/storage-BPJwmlva.cjs +1 -0
- package/dist/storage-D87xFySf.js +85 -0
- package/dist/supports-BvrzQAVk.js +79 -0
- package/dist/supports-C0y3-V5V.cjs +1 -0
- package/dist/types/client.d.ts +23 -119
- package/dist/types/client.d.ts.map +1 -1
- package/dist/types/entities/component/component.d.ts +6 -45
- package/dist/types/entities/component/component.d.ts.map +1 -1
- package/dist/types/entities/experience/experience.d.ts +99 -160
- package/dist/types/entities/experience/experience.d.ts.map +1 -1
- package/dist/types/entities/experience-instance/experience-instance.d.ts +113 -83
- package/dist/types/entities/experience-instance/experience-instance.d.ts.map +1 -1
- package/dist/types/entities/feature/feature.d.ts +8 -118
- package/dist/types/entities/feature/feature.d.ts.map +1 -1
- package/dist/types/entities/field/field.d.ts +64 -96
- package/dist/types/entities/field/field.d.ts.map +1 -1
- package/dist/types/entities/framework/framework.d.ts +7 -32
- package/dist/types/entities/framework/framework.d.ts.map +1 -1
- package/dist/types/entities/history/history.d.ts +6 -6
- package/dist/types/entities/history/history.d.ts.map +1 -1
- package/dist/types/entities/plugin/plugin.d.ts +2 -41
- package/dist/types/entities/plugin/plugin.d.ts.map +1 -1
- package/dist/types/entities/predicate/predicate.d.ts +7 -30
- package/dist/types/entities/predicate/predicate.d.ts.map +1 -1
- package/dist/types/entities/project/project.d.ts +9 -0
- package/dist/types/entities/project/project.d.ts.map +1 -0
- package/dist/types/entities/response/response.d.ts +21 -57
- package/dist/types/entities/response/response.d.ts.map +1 -1
- package/dist/types/exports.d.ts +4 -22
- package/dist/types/exports.d.ts.map +1 -1
- package/dist/types/index.d.ts +3 -12
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/logic-engine.d.ts +11 -13
- package/dist/types/logic-engine.d.ts.map +1 -1
- package/dist/types/picked.d.ts +184 -381
- package/dist/types/picked.d.ts.map +1 -1
- package/dist/types/ping.d.ts +10 -0
- package/dist/types/ping.d.ts.map +1 -0
- package/dist/types/plugins/create-experience/create-experience.d.ts +44 -119
- package/dist/types/plugins/create-experience/create-experience.d.ts.map +1 -1
- package/dist/types/plugins/create-experience/index.d.ts +2 -2
- package/dist/types/plugins/create-experience/index.d.ts.map +1 -1
- package/dist/types/plugins/create-experience/plugin.d.ts +2 -3
- package/dist/types/plugins/create-experience/plugin.d.ts.map +1 -1
- package/dist/types/plugins/create-experience/serialization.d.ts.map +1 -1
- package/dist/types/plugins/experience-browserstorage-plugin/index.d.ts.map +1 -0
- package/dist/types/plugins/experience-browserstorage-plugin/plugin.d.ts +6 -0
- package/dist/types/plugins/experience-browserstorage-plugin/plugin.d.ts.map +1 -0
- package/dist/types/plugins/history-browserstorage-plugin/index.d.ts.map +1 -0
- package/dist/types/plugins/{history-browser-storage → history-browserstorage-plugin}/plugin.d.ts +1 -2
- package/dist/types/plugins/history-browserstorage-plugin/plugin.d.ts.map +1 -0
- package/dist/types/plugins/responses-browserstorage-plugin/index.d.ts.map +1 -0
- package/dist/types/plugins/responses-browserstorage-plugin/plugin.d.ts +6 -0
- package/dist/types/plugins/responses-browserstorage-plugin/plugin.d.ts.map +1 -0
- package/dist/types/plugins/responses-indexeddb-plugin/index.d.ts.map +1 -0
- package/dist/types/plugins/responses-indexeddb-plugin/plugin.d.ts +3 -0
- package/dist/types/plugins/responses-indexeddb-plugin/plugin.d.ts.map +1 -0
- package/dist/types/plugins/shopify/index.d.ts +2 -0
- package/dist/types/plugins/shopify/index.d.ts.map +1 -0
- package/dist/types/plugins/shopify/plugin.d.ts +3 -0
- package/dist/types/plugins/shopify/plugin.d.ts.map +1 -0
- package/dist/types/plugins/shopify/shopify.d.ts +28 -0
- package/dist/types/plugins/shopify/shopify.d.ts.map +1 -0
- package/dist/types/plugins/single-page-app/plugin.d.ts +2 -2
- package/dist/types/plugins/single-page-app/plugin.d.ts.map +1 -1
- package/dist/types/plugins/window-object/plugin.d.ts +2 -2
- package/dist/types/server/index.d.ts +3 -18
- package/dist/types/server/index.d.ts.map +1 -1
- package/dist/types/utils/dom.d.ts +6 -4
- package/dist/types/utils/dom.d.ts.map +1 -1
- package/dist/types/utils/events.d.ts +38 -83
- package/dist/types/utils/events.d.ts.map +1 -1
- package/dist/types/utils/global-obj.d.ts +2 -1
- package/dist/types/utils/global-obj.d.ts.map +1 -1
- package/dist/types/utils/id.d.ts.map +1 -1
- package/dist/types/utils/indexed-db.d.ts +1 -2
- package/dist/types/utils/indexed-db.d.ts.map +1 -1
- package/dist/types/utils/logger.d.ts +1 -2
- package/dist/types/utils/logger.d.ts.map +1 -1
- package/dist/types/utils/node-tree/get-next-node-from-conditional.d.ts +3 -0
- package/dist/types/utils/node-tree/get-next-node-from-conditional.d.ts.map +1 -0
- package/dist/types/utils/node-tree/get-next-node.d.ts +1 -1
- package/dist/types/utils/node-tree/get-next-node.d.ts.map +1 -1
- package/dist/types/utils/node-tree/get-origin-node.d.ts +1 -1
- package/dist/types/utils/node-tree/get-origin-node.d.ts.map +1 -1
- package/dist/types/utils/node-tree/min-max-steps-to-leaf.d.ts +7 -17
- package/dist/types/utils/node-tree/min-max-steps-to-leaf.d.ts.map +1 -1
- package/dist/types/utils/node-tree/min-max-steps-to-origin.d.ts +8 -19
- package/dist/types/utils/node-tree/min-max-steps-to-origin.d.ts.map +1 -1
- package/dist/types/utils/node-tree/next-reachable-step-nodes.d.ts +7 -31
- package/dist/types/utils/node-tree/next-reachable-step-nodes.d.ts.map +1 -1
- package/dist/types/utils/nodes.d.ts +2 -3
- package/dist/types/utils/nodes.d.ts.map +1 -1
- package/dist/types/utils/object.d.ts +8 -0
- package/dist/types/utils/object.d.ts.map +1 -1
- package/dist/types/utils/rules-logic.d.ts +3 -33
- package/dist/types/utils/rules-logic.d.ts.map +1 -1
- package/dist/types/utils/search-params.d.ts.map +1 -1
- package/dist/types/utils/state-snaphot.d.ts +16 -0
- package/dist/types/utils/state-snaphot.d.ts.map +1 -0
- package/dist/types/utils/storage.d.ts +11 -374
- package/dist/types/utils/storage.d.ts.map +1 -1
- package/dist/types/utils/supports.d.ts +0 -87
- package/dist/types/utils/supports.d.ts.map +1 -1
- package/package.json +49 -182
- package/dist/.tsbuildinfo +0 -1
- package/dist/api-C7q_7vxn.js +0 -22
- package/dist/api-Ctvh1qkk.cjs +0 -1
- package/dist/cjs/form/index.js +0 -1
- package/dist/cjs/plugins/dom-observer/index.js +0 -1
- package/dist/cjs/plugins/dynamic-experiences/index.js +0 -1
- package/dist/cjs/plugins/experience-browser-storage/index.js +0 -1
- package/dist/cjs/plugins/history-browser-storage/index.js +0 -1
- package/dist/cjs/plugins/responses-browser-storage/index.js +0 -1
- package/dist/cjs/plugins/responses-indexeddb/index.js +0 -1
- package/dist/cjs/plugins/telemetry/index.js +0 -1
- package/dist/cjs/plugins/web-components/index.js +0 -1
- package/dist/cjs/preview/index.js +0 -1
- package/dist/docs/_root.css +0 -101
- package/dist/docs/explanation/conditions-and-the-logic-engine.md +0 -94
- package/dist/docs/explanation/content-references.md +0 -99
- package/dist/docs/explanation/feature-flag-allocation.md +0 -218
- package/dist/docs/explanation/how-picked-works.md +0 -124
- package/dist/docs/explanation/how-pickedql-works.md +0 -76
- package/dist/docs/explanation/pages-and-flows.md +0 -64
- package/dist/docs/explanation/the-content-model.md +0 -87
- package/dist/docs/explanation/the-two-apis.md +0 -68
- package/dist/docs/explanation/why-server-side-rendering.md +0 -76
- package/dist/docs/explanation/workspaces-and-versions.md +0 -71
- package/dist/docs/how-to/add-a-step-field-or-action.md +0 -43
- package/dist/docs/how-to/analytics/index.md +0 -316
- package/dist/docs/how-to/archive-or-delete-a-workspace.md +0 -46
- package/dist/docs/how-to/authenticate-the-cli.md +0 -97
- package/dist/docs/how-to/authenticate-with-a-magic-link.md +0 -40
- package/dist/docs/how-to/authenticate-with-a-password.md +0 -51
- package/dist/docs/how-to/authenticate-with-an-api-key.md +0 -51
- package/dist/docs/how-to/authenticate-with-oauth.md +0 -40
- package/dist/docs/how-to/build-a-flow.md +0 -83
- package/dist/docs/how-to/connect-the-mcp-server.md +0 -38
- package/dist/docs/how-to/create-a-content-entry.md +0 -48
- package/dist/docs/how-to/create-a-project.md +0 -29
- package/dist/docs/how-to/create-an-experience.md +0 -42
- package/dist/docs/how-to/create-and-revoke-an-api-key.md +0 -42
- package/dist/docs/how-to/debug-with-the-chrome-extension.md +0 -57
- package/dist/docs/how-to/define-a-page-layout.md +0 -46
- package/dist/docs/how-to/fill-and-publish-a-page.md +0 -66
- package/dist/docs/how-to/install-the-gtm-template.md +0 -84
- package/dist/docs/how-to/install-the-sdk.md +0 -93
- package/dist/docs/how-to/install-the-vite-plugin.md +0 -69
- package/dist/docs/how-to/invite-and-remove-members.md +0 -35
- package/dist/docs/how-to/point-one-entry-at-another.md +0 -61
- package/dist/docs/how-to/preview-a-workspace.md +0 -28
- package/dist/docs/how-to/publish-a-workspace.md +0 -30
- package/dist/docs/how-to/read-a-feature-flag.md +0 -113
- package/dist/docs/how-to/read-a-referenced-entry.md +0 -109
- package/dist/docs/how-to/register-a-component.md +0 -55
- package/dist/docs/how-to/register-an-action-handler.md +0 -67
- package/dist/docs/how-to/render-a-step-form.md +0 -131
- package/dist/docs/how-to/render-an-unpublished-preview.md +0 -41
- package/dist/docs/how-to/reuse-a-section.md +0 -53
- package/dist/docs/how-to/reuse-a-step-field-or-action.md +0 -28
- package/dist/docs/how-to/roll-back-a-published-version.md +0 -26
- package/dist/docs/how-to/run-an-ab-test.md +0 -49
- package/dist/docs/how-to/run-code-on-a-form-submission.md +0 -125
- package/dist/docs/how-to/server-render-a-page.md +0 -81
- package/dist/docs/how-to/set-a-content-security-policy.md +0 -32
- package/dist/docs/how-to/set-up-mfa.md +0 -69
- package/dist/docs/how-to/switch-workspaces.md +0 -122
- package/dist/docs/how-to/upload-and-use-an-asset.mdx +0 -73
- package/dist/docs/how-to/validate-a-field.md +0 -52
- package/dist/docs/how-to/write-a-condition.md +0 -45
- package/dist/docs/how-to/write-a-predicate.md +0 -60
- package/dist/docs/index.md +0 -59
- package/dist/docs/reference/dashboard/actions.mdx +0 -53
- package/dist/docs/reference/dashboard/api-keys.mdx +0 -38
- package/dist/docs/reference/dashboard/conditions.mdx +0 -42
- package/dist/docs/reference/dashboard/content/asset-library.mdx +0 -63
- package/dist/docs/reference/dashboard/content/blocks.mdx +0 -57
- package/dist/docs/reference/dashboard/content/content-entries.mdx +0 -95
- package/dist/docs/reference/dashboard/content/models.mdx +0 -108
- package/dist/docs/reference/dashboard/content/pages.mdx +0 -61
- package/dist/docs/reference/dashboard/experiences.mdx +0 -51
- package/dist/docs/reference/dashboard/features.mdx +0 -154
- package/dist/docs/reference/dashboard/fields.mdx +0 -106
- package/dist/docs/reference/dashboard/flow-builder/canvas.mdx +0 -58
- package/dist/docs/reference/dashboard/flow-builder/condition-builder.md +0 -57
- package/dist/docs/reference/dashboard/flow-builder/keyboard-shortcuts.md +0 -72
- package/dist/docs/reference/dashboard/flow-builder/nodes.md +0 -63
- package/dist/docs/reference/dashboard/projects.mdx +0 -44
- package/dist/docs/reference/dashboard/reports.mdx +0 -43
- package/dist/docs/reference/dashboard/steps.mdx +0 -37
- package/dist/docs/reference/dashboard/team-management.md +0 -29
- package/dist/docs/reference/dashboard/workspace-versioning.mdx +0 -30
- package/dist/docs/reference/dashboard/workspaces.mdx +0 -76
- package/dist/docs/reference/delivery-api/experience-content.md +0 -152
- package/dist/docs/reference/delivery-api/index.md +0 -45
- package/dist/docs/reference/delivery-api/preview-caching-crawling.md +0 -79
- package/dist/docs/reference/delivery-api/project-config.md +0 -65
- package/dist/docs/reference/delivery-api/workspace-schema.md +0 -85
- package/dist/docs/reference/glossary.md +0 -181
- package/dist/docs/reference/management-api/authentication.md +0 -74
- package/dist/docs/reference/management-api/authorization-and-scopes.md +0 -285
- package/dist/docs/reference/management-api/error-handling.md +0 -233
- package/dist/docs/reference/management-api/pagination.md +0 -192
- package/dist/docs/reference/pickedql/data-sources.md +0 -174
- package/dist/docs/reference/pickedql/dimensions.md +0 -103
- package/dist/docs/reference/pickedql/filtering.md +0 -64
- package/dist/docs/reference/pickedql/index.md +0 -18
- package/dist/docs/reference/pickedql/schema.md +0 -172
- package/dist/docs/reference/pickedql/virtual-functions.md +0 -248
- package/dist/docs/reference/sdk/actions.md +0 -30
- package/dist/docs/reference/sdk/analytics-events.md +0 -445
- package/dist/docs/reference/sdk/conditions.md +0 -147
- package/dist/docs/reference/sdk/content-security-policy.md +0 -21
- package/dist/docs/reference/sdk/content.md +0 -213
- package/dist/docs/reference/sdk/experiences.md +0 -51
- package/dist/docs/reference/sdk/features.md +0 -256
- package/dist/docs/reference/sdk/fields.md +0 -255
- package/dist/docs/reference/sdk/index.md +0 -68
- package/dist/docs/reference/sdk/plugins/create-experience.md +0 -123
- package/dist/docs/reference/sdk/plugins/dynamic-experiences.md +0 -74
- package/dist/docs/reference/sdk/plugins/index.md +0 -29
- package/dist/docs/reference/sdk/plugins/window-object.md +0 -25
- package/dist/docs/reference/sdk/predicates.md +0 -43
- package/dist/docs/reference/sdk/ssr/index.md +0 -33
- package/dist/docs/reference/sdk/ssr/rendering-and-hydration.md +0 -103
- package/dist/docs/reference/sdk/ssr/serialize.md +0 -80
- package/dist/docs/reference/sdk/ssr/slots-and-placements.md +0 -59
- package/dist/docs/reference/sdk/steps.md +0 -86
- package/dist/docs/reference/sdk/type-generation.md +0 -196
- package/dist/docs/reference/tools/chrome-extension.md +0 -16
- package/dist/docs/reference/tools/cli.md +0 -146
- package/dist/docs/reference/tools/image-optimisation-service.md +0 -104
- package/dist/docs/reference/tools/mcp.md +0 -90
- package/dist/docs/reference/tools/vite-plugin.md +0 -163
- package/dist/docs/tutorials/first-api-call.md +0 -228
- package/dist/docs/tutorials/first-experience-in-the-dashboard.mdx +0 -143
- package/dist/docs/tutorials/first-experience.mdx +0 -254
- package/dist/docs/tutorials/first-server-rendered-page.mdx +0 -186
- package/dist/dom-BqcToNL0.js +0 -82
- package/dist/dom-DlLH3FxV.cjs +0 -1
- package/dist/emit-D-tLiWL1.cjs +0 -1
- package/dist/emit-Ds2EG7CB.js +0 -14
- package/dist/esm/form/index.js +0 -565
- package/dist/esm/plugins/dom-observer/index.js +0 -87
- package/dist/esm/plugins/dynamic-experiences/index.js +0 -5
- package/dist/esm/plugins/experience-browser-storage/index.js +0 -38
- package/dist/esm/plugins/history-browser-storage/index.js +0 -26
- package/dist/esm/plugins/responses-browser-storage/index.js +0 -71
- package/dist/esm/plugins/responses-indexeddb/index.js +0 -89
- package/dist/esm/plugins/telemetry/index.js +0 -100
- package/dist/esm/plugins/web-components/index.js +0 -19
- package/dist/esm/preview/index.js +0 -2
- package/dist/experience-instance-B9S6Yf0N.js +0 -711
- package/dist/experience-instance-D8rOg6We.cjs +0 -1
- package/dist/id-Bo4RBeOs.js +0 -4
- package/dist/id-Js-62re-.cjs +0 -1
- package/dist/inert-script-report-B_bMPRzp.js +0 -18
- package/dist/inert-script-report-ijRHPtcY.cjs +0 -1
- package/dist/logger-CSTvAyyB.cjs +0 -1
- package/dist/logger-DMN6TxJJ.js +0 -4
- package/dist/object-BUDGxEqy.js +0 -25
- package/dist/object-CIkt7Fkr.cjs +0 -1
- package/dist/plugin-ChafFq6S.js +0 -194
- package/dist/plugin-Dn25Gffy.cjs +0 -1
- package/dist/preview-channel-CSr96XAo.js +0 -98
- package/dist/preview-channel-Cx0e6fye.cjs +0 -1
- package/dist/protocol-Bb_vpLKE.cjs +0 -1
- package/dist/protocol-C5KkkiZc.js +0 -84
- package/dist/provider-B8wvmeC8.js +0 -98
- package/dist/provider-BBLlQOjV.cjs +0 -1
- package/dist/registry-C1t8l3t9.cjs +0 -1
- package/dist/registry-CXZv0uLg.js +0 -18
- package/dist/rules-logic-CGZIYgAI.cjs +0 -1
- package/dist/rules-logic-HesIUCu6.js +0 -13
- package/dist/storage-1MW3-_As.js +0 -103
- package/dist/storage-DUw9UJ2h.cjs +0 -1
- package/dist/supports-CO9bJGNl.js +0 -92
- package/dist/supports-DBzjGaWD.cjs +0 -1
- package/dist/types/data-source/api.d.ts +0 -60
- package/dist/types/data-source/api.d.ts.map +0 -1
- package/dist/types/data-source/provider.d.ts +0 -103
- package/dist/types/data-source/provider.d.ts.map +0 -1
- package/dist/types/data-source/registry.d.ts +0 -26
- package/dist/types/data-source/registry.d.ts.map +0 -1
- package/dist/types/data-source/request-observer.d.ts +0 -62
- package/dist/types/data-source/request-observer.d.ts.map +0 -1
- package/dist/types/data-source/virtual-data.d.ts +0 -19
- package/dist/types/data-source/virtual-data.d.ts.map +0 -1
- package/dist/types/entities/action/action.d.ts +0 -85
- package/dist/types/entities/action/action.d.ts.map +0 -1
- package/dist/types/entities/component/lazyComponent.d.ts +0 -11
- package/dist/types/entities/component/lazyComponent.d.ts.map +0 -1
- package/dist/types/entities/condition/condition.d.ts +0 -29
- package/dist/types/entities/condition/condition.d.ts.map +0 -1
- package/dist/types/entities/content/content.d.ts +0 -53
- package/dist/types/entities/content/content.d.ts.map +0 -1
- package/dist/types/entities/content/reference.d.ts +0 -101
- package/dist/types/entities/content/reference.d.ts.map +0 -1
- package/dist/types/entities/field/policies.d.ts +0 -35
- package/dist/types/entities/field/policies.d.ts.map +0 -1
- package/dist/types/entities/response/response-validation.d.ts +0 -75
- package/dist/types/entities/response/response-validation.d.ts.map +0 -1
- package/dist/types/entities/session/session.d.ts +0 -46
- package/dist/types/entities/session/session.d.ts.map +0 -1
- package/dist/types/entities/step/step.d.ts +0 -56
- package/dist/types/entities/step/step.d.ts.map +0 -1
- package/dist/types/form/build-responses.d.ts +0 -18
- package/dist/types/form/build-responses.d.ts.map +0 -1
- package/dist/types/form/create-field-evaluator.d.ts +0 -28
- package/dist/types/form/create-field-evaluator.d.ts.map +0 -1
- package/dist/types/form/create-field-validation.d.ts +0 -60
- package/dist/types/form/create-field-validation.d.ts.map +0 -1
- package/dist/types/form/create-form.d.ts +0 -153
- package/dist/types/form/create-form.d.ts.map +0 -1
- package/dist/types/form/create-submit-pipeline.d.ts +0 -116
- package/dist/types/form/create-submit-pipeline.d.ts.map +0 -1
- package/dist/types/form/get-step-fields.d.ts +0 -19
- package/dist/types/form/get-step-fields.d.ts.map +0 -1
- package/dist/types/form/index.d.ts +0 -11
- package/dist/types/form/index.d.ts.map +0 -1
- package/dist/types/lifecycle/condition-selection.d.ts +0 -146
- package/dist/types/lifecycle/condition-selection.d.ts.map +0 -1
- package/dist/types/lifecycle/lifecycle.d.ts +0 -48
- package/dist/types/lifecycle/lifecycle.d.ts.map +0 -1
- package/dist/types/lifecycle/rules-logic.d.ts +0 -25
- package/dist/types/lifecycle/rules-logic.d.ts.map +0 -1
- package/dist/types/lifecycle/state-snapshot.d.ts +0 -38
- package/dist/types/lifecycle/state-snapshot.d.ts.map +0 -1
- package/dist/types/plugins/dom-observer/index.d.ts +0 -3
- package/dist/types/plugins/dom-observer/index.d.ts.map +0 -1
- package/dist/types/plugins/dom-observer/plugin.d.ts +0 -50
- package/dist/types/plugins/dom-observer/plugin.d.ts.map +0 -1
- package/dist/types/plugins/dynamic-experiences/hash.d.ts +0 -105
- package/dist/types/plugins/dynamic-experiences/hash.d.ts.map +0 -1
- package/dist/types/plugins/dynamic-experiences/index.d.ts +0 -7
- package/dist/types/plugins/dynamic-experiences/index.d.ts.map +0 -1
- package/dist/types/plugins/dynamic-experiences/plugin.d.ts +0 -49
- package/dist/types/plugins/dynamic-experiences/plugin.d.ts.map +0 -1
- package/dist/types/plugins/dynamic-experiences/types.d.ts +0 -45
- package/dist/types/plugins/dynamic-experiences/types.d.ts.map +0 -1
- package/dist/types/plugins/experience-browser-storage/index.d.ts.map +0 -1
- package/dist/types/plugins/experience-browser-storage/plugin.d.ts +0 -7
- package/dist/types/plugins/experience-browser-storage/plugin.d.ts.map +0 -1
- package/dist/types/plugins/history-browser-storage/index.d.ts.map +0 -1
- package/dist/types/plugins/history-browser-storage/plugin.d.ts.map +0 -1
- package/dist/types/plugins/responses-browser-storage/index.d.ts.map +0 -1
- package/dist/types/plugins/responses-browser-storage/plugin.d.ts +0 -18
- package/dist/types/plugins/responses-browser-storage/plugin.d.ts.map +0 -1
- package/dist/types/plugins/responses-indexeddb/index.d.ts.map +0 -1
- package/dist/types/plugins/responses-indexeddb/plugin.d.ts +0 -3
- package/dist/types/plugins/responses-indexeddb/plugin.d.ts.map +0 -1
- package/dist/types/plugins/telemetry/emit.d.ts +0 -18
- package/dist/types/plugins/telemetry/emit.d.ts.map +0 -1
- package/dist/types/plugins/telemetry/index.d.ts +0 -4
- package/dist/types/plugins/telemetry/index.d.ts.map +0 -1
- package/dist/types/plugins/telemetry/plugin-summary.d.ts +0 -10
- package/dist/types/plugins/telemetry/plugin-summary.d.ts.map +0 -1
- package/dist/types/plugins/telemetry/plugin.d.ts +0 -45
- package/dist/types/plugins/telemetry/plugin.d.ts.map +0 -1
- package/dist/types/plugins/web-components/index.d.ts +0 -2
- package/dist/types/plugins/web-components/index.d.ts.map +0 -1
- package/dist/types/plugins/web-components/plugin.d.ts +0 -4
- package/dist/types/plugins/web-components/plugin.d.ts.map +0 -1
- package/dist/types/preview/index.d.ts +0 -18
- package/dist/types/preview/index.d.ts.map +0 -1
- package/dist/types/preview-bridge/index.d.ts +0 -14
- package/dist/types/preview-bridge/index.d.ts.map +0 -1
- package/dist/types/preview-channel.d.ts +0 -16
- package/dist/types/preview-channel.d.ts.map +0 -1
- package/dist/types/preview-receiver/apply-ops.d.ts +0 -32
- package/dist/types/preview-receiver/apply-ops.d.ts.map +0 -1
- package/dist/types/preview-receiver/index.d.ts +0 -32
- package/dist/types/preview-receiver/index.d.ts.map +0 -1
- package/dist/types/preview-receiver/protocol.d.ts +0 -69
- package/dist/types/preview-receiver/protocol.d.ts.map +0 -1
- package/dist/types/schema-registry.d.ts +0 -206
- package/dist/types/schema-registry.d.ts.map +0 -1
- package/dist/types/server/serialize.d.ts +0 -87
- package/dist/types/server/serialize.d.ts.map +0 -1
- package/dist/types/typed-content.d.ts +0 -17
- package/dist/types/typed-content.d.ts.map +0 -1
- package/dist/types/utils/client-telemetry.d.ts +0 -25
- package/dist/types/utils/client-telemetry.d.ts.map +0 -1
- package/dist/types/utils/content-path.d.ts +0 -37
- package/dist/types/utils/content-path.d.ts.map +0 -1
- package/dist/types/utils/html-asset-value.d.ts +0 -20
- package/dist/types/utils/html-asset-value.d.ts.map +0 -1
- package/dist/types/utils/inert-script-report.d.ts +0 -40
- package/dist/types/utils/inert-script-report.d.ts.map +0 -1
- package/dist/types/utils/node-tree/get-next-node-from-action.d.ts +0 -25
- package/dist/types/utils/node-tree/get-next-node-from-action.d.ts.map +0 -1
- package/dist/types/utils/node-tree/get-next-node-from-condition.d.ts +0 -17
- package/dist/types/utils/node-tree/get-next-node-from-condition.d.ts.map +0 -1
- package/dist/types/utils/node-tree/node-adjacency.d.ts +0 -50
- package/dist/types/utils/node-tree/node-adjacency.d.ts.map +0 -1
- package/dist/types/utils/node-tree/node-tree-index.d.ts +0 -57
- package/dist/types/utils/node-tree/node-tree-index.d.ts.map +0 -1
- package/dist/types/utils/picked-config.d.ts +0 -39
- package/dist/types/utils/picked-config.d.ts.map +0 -1
- package/dist/types/utils/preview-session.d.ts +0 -12
- package/dist/types/utils/preview-session.d.ts.map +0 -1
- package/dist/types/utils/rehydrate-scripts.d.ts +0 -50
- package/dist/types/utils/rehydrate-scripts.d.ts.map +0 -1
- package/dist/types/utils/render-string.d.ts +0 -24
- package/dist/types/utils/render-string.d.ts.map +0 -1
- package/dist/types/utils/user-timing.d.ts +0 -21
- package/dist/types/utils/user-timing.d.ts.map +0 -1
- package/dist/version-CLjPfmxk.cjs +0 -1
- package/dist/version-CPKulHMH.js +0 -256
- /package/dist/types/plugins/{experience-browser-storage → experience-browserstorage-plugin}/index.d.ts +0 -0
- /package/dist/types/plugins/{history-browser-storage → history-browserstorage-plugin}/index.d.ts +0 -0
- /package/dist/types/plugins/{responses-browser-storage → responses-browserstorage-plugin}/index.d.ts +0 -0
- /package/dist/types/plugins/{responses-indexeddb → responses-indexeddb-plugin}/index.d.ts +0 -0
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
type: how-to
|
|
3
|
-
layout: docs
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# How to define a page layout
|
|
7
|
-
|
|
8
|
-
This guide shows you how to define the shape of a page. A page layout sets which fields a
|
|
9
|
-
page can hold, and it holds no data itself.
|
|
10
|
-
|
|
11
|
-
## Steps
|
|
12
|
-
|
|
13
|
-
1. Open your workspace.
|
|
14
|
-
2. Click **Pages** in the sidebar, then **Page Layouts**.
|
|
15
|
-
3. Click **New model**.
|
|
16
|
-
4. Set **Category** to **Page layout**.
|
|
17
|
-
5. Enter a **Name** and a **Key**. The key is stable, and your SDK code and your API
|
|
18
|
-
calls both use it.
|
|
19
|
-
6. Add your fields. Choose a type for each one.
|
|
20
|
-
7. Click **Create model**.
|
|
21
|
-
|
|
22
|
-
The category is fixed when you create the Model. You cannot change it later.
|
|
23
|
-
|
|
24
|
-
## Make a field repeatable
|
|
25
|
-
|
|
26
|
-
Turn on **repeatable** on any field. It then renders as a sortable list of values. Use it
|
|
27
|
-
for a gallery, or for a list of features.
|
|
28
|
-
|
|
29
|
-
## Group related fields
|
|
30
|
-
|
|
31
|
-
Add a **Group** field to hold a set of fields under one key. Make the group repeatable to
|
|
32
|
-
describe a list of objects, such as a list of feature cards.
|
|
33
|
-
|
|
34
|
-
## Define content with no layout role
|
|
35
|
-
|
|
36
|
-
A Model needs no category. Leave **Category** as **None (general content)** for content
|
|
37
|
-
that no Page and no Step renders, such as an author or a product. Reach such a Model
|
|
38
|
-
under **CMS** in the sidebar, and point at its entries with a **Reference** field.
|
|
39
|
-
|
|
40
|
-
## Related
|
|
41
|
-
|
|
42
|
-
- [About the content model](/explanation/the-content-model) — why the schema and the data
|
|
43
|
-
are separate.
|
|
44
|
-
- [Models](/reference/dashboard/content/models) — every field type.
|
|
45
|
-
- [How to reuse a section](/how-to/reuse-a-section)
|
|
46
|
-
- [How to point one entry at another](/how-to/point-one-entry-at-another)
|
|
@@ -1,66 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
type: how-to
|
|
3
|
-
layout: docs
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# How to fill and publish a page
|
|
7
|
-
|
|
8
|
-
This guide shows you how to make a server-rendered Page and put content in it. You need a
|
|
9
|
-
page layout first. See [How to define a page layout](/how-to/define-a-page-layout).
|
|
10
|
-
|
|
11
|
-
## 1. Create the page
|
|
12
|
-
|
|
13
|
-
1. Open your project.
|
|
14
|
-
2. Choose a workspace.
|
|
15
|
-
3. Click **Pages** in the sidebar.
|
|
16
|
-
4. Click **New experience**.
|
|
17
|
-
5. Choose the **Page** type.
|
|
18
|
-
6. Choose a page layout.
|
|
19
|
-
7. Click **Create page**.
|
|
20
|
-
|
|
21
|
-
Picked makes a content entry and links it to the page on the first save.
|
|
22
|
-
|
|
23
|
-
## 2. Fill in the content
|
|
24
|
-
|
|
25
|
-
1. Open the **Properties** tab.
|
|
26
|
-
2. Fill in each field. The inspector on the right edits the field that you choose.
|
|
27
|
-
3. Watch the preview panel as the page fills in.
|
|
28
|
-
|
|
29
|
-
## 3. Correct every error
|
|
30
|
-
|
|
31
|
-
An invalid field shows an error next to it while you edit. Correct each one before you
|
|
32
|
-
publish. Picked serves valid content only.
|
|
33
|
-
|
|
34
|
-
## 4. Choose the status
|
|
35
|
-
|
|
36
|
-
Open the **Settings** tab and set the status.
|
|
37
|
-
|
|
38
|
-
- Set **Active** to serve the page to everyone.
|
|
39
|
-
- Set **Draft** to keep the page out of the published site. Picked serves a
|
|
40
|
-
draft page through a preview link, and to nobody else.
|
|
41
|
-
|
|
42
|
-
Use **Draft** for a page that is ready to review but not ready to be public.
|
|
43
|
-
When you publish the workspace, Picked releases your other changes and leaves
|
|
44
|
-
that page staged.
|
|
45
|
-
|
|
46
|
-
## 5. Publish
|
|
47
|
-
|
|
48
|
-
Publish the workspace to apply your changes to the live site. See
|
|
49
|
-
[How to publish a workspace](/how-to/publish-a-workspace).
|
|
50
|
-
|
|
51
|
-
When you publish the workspace, Picked does not make a draft page public. To
|
|
52
|
-
make that page public, set the status to **Active** and publish the workspace
|
|
53
|
-
again.
|
|
54
|
-
|
|
55
|
-
## Change the layout later
|
|
56
|
-
|
|
57
|
-
Use the change-layout control on the **Settings** tab. When you unlink a layout, Picked
|
|
58
|
-
separates the content entry from the page. It deletes no entry, but the page then has no
|
|
59
|
-
content to render.
|
|
60
|
-
|
|
61
|
-
## Related
|
|
62
|
-
|
|
63
|
-
- [About pages and flows](/explanation/pages-and-flows) — when to choose a Page.
|
|
64
|
-
- [Your first server-rendered page](/tutorials/first-server-rendered-page) — the whole
|
|
65
|
-
path, with the SDK.
|
|
66
|
-
- [Pages](/reference/dashboard/content/pages) — the editor reference.
|
|
@@ -1,84 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
type: how-to
|
|
3
|
-
layout: docs
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# How to install the GTM template
|
|
7
|
-
|
|
8
|
-
This guide shows you how to track an ecommerce event in Google Tag Manager and send it to
|
|
9
|
-
Picked. You need a GTM container and your Picked Tag ID.
|
|
10
|
-
|
|
11
|
-
## Automatic installation
|
|
12
|
-
|
|
13
|
-
Install the template from the GTM Community Gallery:
|
|
14
|
-
|
|
15
|
-
1. In Tag Manager, click **Templates**.
|
|
16
|
-
2. In the **Tag Templates** section, click **Search Gallery**.
|
|
17
|
-
3. Search for `Picked Ecommerce`.
|
|
18
|
-
4. Click the Picked Ecommerce template to read its detail.
|
|
19
|
-
5. Click the **Add to workspace** button.
|
|
20
|
-
6. Read the permissions that it needs.
|
|
21
|
-
7. Click **Add**.
|
|
22
|
-
|
|
23
|
-

|
|
24
|
-
|
|
25
|
-
## Manual installation
|
|
26
|
-
|
|
27
|
-
To import the template file yourself:
|
|
28
|
-
|
|
29
|
-
1. Download the
|
|
30
|
-
[template file](https://github.com/picked-app/gtm-template/blob/main/template.tpl)
|
|
31
|
-
from GitHub with the download icon.
|
|
32
|
-
2. In Google Tag Manager, go to **Templates**.
|
|
33
|
-
3. Click **New**.
|
|
34
|
-
4. Open the three-dot menu.
|
|
35
|
-
5. Click **Import**.
|
|
36
|
-
6. Choose the file that you downloaded.
|
|
37
|
-
7. Click **Save**.
|
|
38
|
-
|
|
39
|
-
## Setup
|
|
40
|
-
|
|
41
|
-
### 1. Create a Tag ID variable
|
|
42
|
-
|
|
43
|
-
Sign in to the [Picked Dashboard](https://dashboard.picked.app) and copy the Tag ID of
|
|
44
|
-
your project. Save it as a constant variable in GTM, for example `Picked Tag ID`.
|
|
45
|
-
|
|
46
|
-

|
|
47
|
-
|
|
48
|
-
### 2. Create an ecommerce data variable
|
|
49
|
-
|
|
50
|
-
Create a **Data Layer Variable** with the variable name `ecommerce`. It captures what
|
|
51
|
-
GA4 Enhanced Ecommerce writes to the data layer.
|
|
52
|
-
|
|
53
|
-

|
|
54
|
-
|
|
55
|
-
### 3. Create event triggers
|
|
56
|
-
|
|
57
|
-
Add a trigger for each ecommerce event that you want to track, for example
|
|
58
|
-
`add_to_cart`, `purchase`, or `view_item`.
|
|
59
|
-
|
|
60
|
-

|
|
61
|
-
|
|
62
|
-
### 4. Create tags
|
|
63
|
-
|
|
64
|
-
Create a new tag for each event. Choose the tag template called **Picked Ecommerce**. Assign
|
|
65
|
-
the trigger that matches. Then set the options below.
|
|
66
|
-
|
|
67
|
-

|
|
68
|
-
|
|
69
|
-
## Options
|
|
70
|
-
|
|
71
|
-
| Option | Description |
|
|
72
|
-
| --- | --- |
|
|
73
|
-
| **Tag ID** | The Tag ID of your Picked project. Find it in the [Picked Dashboard](https://dashboard.picked.app). |
|
|
74
|
-
| **Event** | The ecommerce event to track, for example `add_to_cart` or `purchase`. |
|
|
75
|
-
| **Send ecommerce data** | Turn this on to send the data from GA4 Enhanced Ecommerce to Picked. Turn it on for every ecommerce event. |
|
|
76
|
-
| **GA4 Enhanced Ecommerce Data** | The GTM variable that holds the data from GA4 Enhanced Ecommerce. Use the data layer variable from step 2. |
|
|
77
|
-
| **Additional data** | An optional GTM variable, for more metadata with the event. |
|
|
78
|
-
|
|
79
|
-

|
|
80
|
-
|
|
81
|
-
## Related
|
|
82
|
-
|
|
83
|
-
- [About how Picked works](/explanation/how-picked-works) — what Picked does with the
|
|
84
|
-
event.
|
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
type: how-to
|
|
3
|
-
layout: docs
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# How to install the SDK
|
|
7
|
-
|
|
8
|
-
This guide shows you how to add the Picked client to a web application. You need a project
|
|
9
|
-
ID from the dashboard.
|
|
10
|
-
|
|
11
|
-
## 1. Install the packages
|
|
12
|
-
|
|
13
|
-
:::code-group
|
|
14
|
-
|
|
15
|
-
```bash [React]
|
|
16
|
-
npm install picked @picked/react
|
|
17
|
-
```
|
|
18
|
-
|
|
19
|
-
```bash [Svelte]
|
|
20
|
-
npm install picked @picked/svelte
|
|
21
|
-
```
|
|
22
|
-
|
|
23
|
-
:::
|
|
24
|
-
|
|
25
|
-
`picked` gives you the client, the `picked.config` helpers, and the `picked` command. Your
|
|
26
|
-
package manager adds `@picked/client` with it, which carries the runtime and holds the
|
|
27
|
-
generated types.
|
|
28
|
-
|
|
29
|
-
## 2. Add `picked.config.ts`
|
|
30
|
-
|
|
31
|
-
Create this file in the root of your project. The `picked` command and the
|
|
32
|
-
[Vite plugin](/reference/tools/vite-plugin) read your project identity from it:
|
|
33
|
-
|
|
34
|
-
```typescript
|
|
35
|
-
import { defineConfig } from 'picked/config'
|
|
36
|
-
|
|
37
|
-
export default defineConfig({
|
|
38
|
-
projectId: 'your-project-id',
|
|
39
|
-
})
|
|
40
|
-
```
|
|
41
|
-
|
|
42
|
-
[Type generation](/reference/sdk/type-generation) reads this file, and gives your fields,
|
|
43
|
-
features and steps the types the workspace declares.
|
|
44
|
-
|
|
45
|
-
## 3. Create and start the client
|
|
46
|
-
|
|
47
|
-
:::code-group
|
|
48
|
-
|
|
49
|
-
```tsx [React]
|
|
50
|
-
import { createClient } from 'picked'
|
|
51
|
-
import { dynamicExperiencesPlugin } from '@picked/client/plugins/dynamic-experiences'
|
|
52
|
-
import { reactFrameworkPlugin } from '@picked/react/plugins/framework'
|
|
53
|
-
|
|
54
|
-
export const picked = createClient({
|
|
55
|
-
projectId: 'your-project-id',
|
|
56
|
-
plugins: [reactFrameworkPlugin({ components: {} }), dynamicExperiencesPlugin()],
|
|
57
|
-
})
|
|
58
|
-
|
|
59
|
-
picked.start()
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
```ts [Svelte]
|
|
63
|
-
import { createClient } from 'picked'
|
|
64
|
-
import { dynamicExperiencesPlugin } from '@picked/client/plugins/dynamic-experiences'
|
|
65
|
-
import { svelteFrameworkPlugin } from '@picked/svelte/plugins/framework'
|
|
66
|
-
|
|
67
|
-
export const picked = createClient({
|
|
68
|
-
projectId: 'your-project-id',
|
|
69
|
-
plugins: [svelteFrameworkPlugin({ components: {} }), dynamicExperiencesPlugin()],
|
|
70
|
-
})
|
|
71
|
-
|
|
72
|
-
picked.start()
|
|
73
|
-
```
|
|
74
|
-
|
|
75
|
-
:::
|
|
76
|
-
|
|
77
|
-
`picked` carries the client's root entry. Each deeper import path, such as
|
|
78
|
-
`@picked/client/plugins/dynamic-experiences` and `@picked/client/server`, keeps its own
|
|
79
|
-
name.
|
|
80
|
-
|
|
81
|
-
`start()` is idempotent. A second call changes nothing on a client that started already.
|
|
82
|
-
|
|
83
|
-
## 4. Add the optional plugins
|
|
84
|
-
|
|
85
|
-
- `windowObjectPlugin()` puts the client on `window.Picked`, which helps when you debug.
|
|
86
|
-
- `singlePageAppPlugin()` starts the client again on a history event.
|
|
87
|
-
|
|
88
|
-
## Related
|
|
89
|
-
|
|
90
|
-
- [Add Picked to your application](/tutorials/first-experience) — the whole path.
|
|
91
|
-
- [SDK installation](/reference/sdk) — every client option.
|
|
92
|
-
- [Type generation](/reference/sdk/type-generation) — types from your workspace.
|
|
93
|
-
- [How to register a component](/how-to/register-a-component).
|
|
@@ -1,69 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
type: how-to
|
|
3
|
-
layout: docs
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# How to install the Vite plugin
|
|
7
|
-
|
|
8
|
-
This guide shows you how to embed your project configuration at build time, so the SDK makes no
|
|
9
|
-
API request at runtime.
|
|
10
|
-
|
|
11
|
-
## 1. Install
|
|
12
|
-
|
|
13
|
-
:::code-group
|
|
14
|
-
|
|
15
|
-
```bash [npm]
|
|
16
|
-
npm install @picked/vite-plugin-picked picked
|
|
17
|
-
```
|
|
18
|
-
|
|
19
|
-
```bash [pnpm]
|
|
20
|
-
pnpm add @picked/vite-plugin-picked picked
|
|
21
|
-
```
|
|
22
|
-
|
|
23
|
-
```bash [yarn]
|
|
24
|
-
yarn add @picked/vite-plugin-picked picked
|
|
25
|
-
```
|
|
26
|
-
|
|
27
|
-
:::
|
|
28
|
-
|
|
29
|
-
## 2. Name your project
|
|
30
|
-
|
|
31
|
-
Create `picked.config.ts` in the root of your project. The plugin reads your project
|
|
32
|
-
identity from this file:
|
|
33
|
-
|
|
34
|
-
```typescript
|
|
35
|
-
import { defineConfig } from 'picked/config'
|
|
36
|
-
|
|
37
|
-
export default defineConfig({
|
|
38
|
-
projectId: 'your-project-id',
|
|
39
|
-
})
|
|
40
|
-
```
|
|
41
|
-
|
|
42
|
-
## 3. Add the plugin to your Vite config
|
|
43
|
-
|
|
44
|
-
```typescript
|
|
45
|
-
import { defineConfig } from 'vite'
|
|
46
|
-
import { picked } from '@picked/vite-plugin-picked'
|
|
47
|
-
|
|
48
|
-
export default defineConfig({
|
|
49
|
-
plugins: [picked()],
|
|
50
|
-
})
|
|
51
|
-
```
|
|
52
|
-
|
|
53
|
-
When Vite starts, the plugin reads your project configuration and embeds them in your bundle.
|
|
54
|
-
The SDK then reads the embedded configuration and makes no network request.
|
|
55
|
-
|
|
56
|
-
The plugin also writes `picked-env.d.ts`, which types your fields, features and steps
|
|
57
|
-
against the workspace. See [Type generation](/reference/sdk/type-generation).
|
|
58
|
-
|
|
59
|
-
:::note
|
|
60
|
-
When a preview token is there at runtime, the SDK ignores the embedded configuration and reads
|
|
61
|
-
fresh data from the API.
|
|
62
|
-
:::
|
|
63
|
-
|
|
64
|
-
## Related
|
|
65
|
-
|
|
66
|
-
- [Vite plugin](/reference/tools/vite-plugin) — every option.
|
|
67
|
-
- [Type generation](/reference/sdk/type-generation) — the `picked.config.ts` options.
|
|
68
|
-
- [About how Picked works](/explanation/how-picked-works) — where build-time configuration sit
|
|
69
|
-
in the startup order.
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
type: how-to
|
|
3
|
-
layout: docs
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# How to invite and remove members
|
|
7
|
-
|
|
8
|
-
This guide shows you how to control who reaches your organization.
|
|
9
|
-
|
|
10
|
-
## Invite a member
|
|
11
|
-
|
|
12
|
-
1. Open your organization.
|
|
13
|
-
2. Click **Members**.
|
|
14
|
-
3. Click **Invite member**.
|
|
15
|
-
4. Enter an email address.
|
|
16
|
-
5. Choose a role. Give the smallest role that the work needs.
|
|
17
|
-
6. Click **Send invitation**.
|
|
18
|
-
|
|
19
|
-
The person receives an email with a link to join. To join, they click the link in the
|
|
20
|
-
email and set a password. They can also go to the register page and enter the same email
|
|
21
|
-
address. Then they confirm the address and set a password.
|
|
22
|
-
|
|
23
|
-
## Remove a member
|
|
24
|
-
|
|
25
|
-
1. Open your organization.
|
|
26
|
-
2. Click **Members**.
|
|
27
|
-
3. Find the member.
|
|
28
|
-
4. Click **Remove** next to the name.
|
|
29
|
-
5. Confirm.
|
|
30
|
-
|
|
31
|
-
The member loses access to every project in the organization immediately.
|
|
32
|
-
|
|
33
|
-
## Related
|
|
34
|
-
|
|
35
|
-
- [Team management](/reference/dashboard/team-management) — the roles.
|
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
type: how-to
|
|
3
|
-
layout: docs
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# How to point one entry at another
|
|
7
|
-
|
|
8
|
-
This guide shows you how to point one content entry at another, such as a product at its
|
|
9
|
-
category. You need two Models: the one that holds the pointer, and the one that the
|
|
10
|
-
pointer reaches.
|
|
11
|
-
|
|
12
|
-
## 1. Create the target Model
|
|
13
|
-
|
|
14
|
-
1. Click **CMS** in the sidebar, then **Models**.
|
|
15
|
-
2. Click **New model**.
|
|
16
|
-
3. Enter a **Name** and a **Key**, such as `category`.
|
|
17
|
-
4. Leave **Category** as **None (general content)**.
|
|
18
|
-
5. Add your fields.
|
|
19
|
-
6. Click **Create model**.
|
|
20
|
-
|
|
21
|
-
## 2. Add a Reference field
|
|
22
|
-
|
|
23
|
-
1. Open the Model that holds the pointer.
|
|
24
|
-
2. Drag a **Reference** property onto the schema.
|
|
25
|
-
3. Enter a **Name** and a **Key**, such as `category`.
|
|
26
|
-
4. Set **Target Model** to the Model from step 1.
|
|
27
|
-
5. Click **Save**.
|
|
28
|
-
|
|
29
|
-
Turn on **repeatable** for a field that points at more than one entry. Leave **Target
|
|
30
|
-
Model** as **Any Model** to accept an entry of any Model in the workspace.
|
|
31
|
-
|
|
32
|
-
## 3. Choose a target on an entry
|
|
33
|
-
|
|
34
|
-
1. Open a content entry that uses the Model.
|
|
35
|
-
2. Find your Reference field.
|
|
36
|
-
3. Click **Choose entry**.
|
|
37
|
-
4. Search for the entry.
|
|
38
|
-
5. Choose the entry.
|
|
39
|
-
6. Click **Save**.
|
|
40
|
-
|
|
41
|
-
Use **Change entry** to point the field somewhere else. Use **Clear** to remove the
|
|
42
|
-
pointer. **Clear** deletes no content.
|
|
43
|
-
|
|
44
|
-
## Delete a target
|
|
45
|
-
|
|
46
|
-
Picked does not delete an entry while another entry points at it. Clear the reference on
|
|
47
|
-
each entry that points at the target, then delete the target.
|
|
48
|
-
|
|
49
|
-
The same rule holds for a Model. Remove the Reference field that holds it as its **Target
|
|
50
|
-
Model** first.
|
|
51
|
-
|
|
52
|
-
## Read it in your code
|
|
53
|
-
|
|
54
|
-
The pointer and the entry travel separately. See
|
|
55
|
-
[How to read a referenced entry](/how-to/read-a-referenced-entry).
|
|
56
|
-
|
|
57
|
-
## Related
|
|
58
|
-
|
|
59
|
-
- [About content references](/explanation/content-references) — why a reference is a pointer.
|
|
60
|
-
- [Models](/reference/dashboard/content/models) — the field and its options.
|
|
61
|
-
- [Content entries](/reference/dashboard/content/content-entries) — the editor reference.
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
type: how-to
|
|
3
|
-
layout: docs
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# How to see a preview of a workspace
|
|
7
|
-
|
|
8
|
-
This guide shows you how to see an unpublished change on your own site before your
|
|
9
|
-
visitors get it. You need a draft workspace with at least one change in it.
|
|
10
|
-
|
|
11
|
-
## Steps
|
|
12
|
-
|
|
13
|
-
1. Click **Preview** in the workspace toolbar.
|
|
14
|
-
2. Enter the URL of your site.
|
|
15
|
-
3. Set each feature flag to the **Default** value, to **On**, or to **Off**. This step
|
|
16
|
-
is optional.
|
|
17
|
-
4. Click **Open preview**.
|
|
18
|
-
|
|
19
|
-
Your site opens in a new tab with the unpublished workspace applied.
|
|
20
|
-
|
|
21
|
-
The preview sends the workspace state to the SDK in the query parameters. The visitors on
|
|
22
|
-
your live site therefore see no change.
|
|
23
|
-
|
|
24
|
-
## Related
|
|
25
|
-
|
|
26
|
-
- [About workspaces and versions](/explanation/workspaces-and-versions) — why a preview
|
|
27
|
-
cannot reach production.
|
|
28
|
-
- [Workspaces](/reference/dashboard/workspaces) — the workspace states.
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
type: how-to
|
|
3
|
-
layout: docs
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# How to publish a workspace
|
|
7
|
-
|
|
8
|
-
This guide shows you how to make the changes in a workspace live. You need a draft
|
|
9
|
-
workspace with at least one unpublished change.
|
|
10
|
-
|
|
11
|
-
The **Publish** button is active only when the workspace holds an unpublished change. A
|
|
12
|
-
badge in the toolbar shows the current state.
|
|
13
|
-
|
|
14
|
-
## Steps
|
|
15
|
-
|
|
16
|
-
1. Click **Publish** in the workspace toolbar.
|
|
17
|
-
2. Read the change preview in the publish modal.
|
|
18
|
-
3. Expand any modified row to see which properties changed.
|
|
19
|
-
4. Read the banner above the diff, if one is there. It reports a change that breaks
|
|
20
|
-
another record.
|
|
21
|
-
5. Click **Publish** to confirm.
|
|
22
|
-
|
|
23
|
-
Picked makes an immutable snapshot of your workspace, and the SDK serves it to your
|
|
24
|
-
visitors.
|
|
25
|
-
|
|
26
|
-
## Related
|
|
27
|
-
|
|
28
|
-
- [About workspaces and versions](/explanation/workspaces-and-versions) — why the modal
|
|
29
|
-
shows a diff.
|
|
30
|
-
- [How to roll back a published version](/how-to/roll-back-a-published-version).
|
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
type: how-to
|
|
3
|
-
layout: docs
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# How to read a feature flag
|
|
7
|
-
|
|
8
|
-
This guide shows you how to read the resolved bucket of a feature flag in your
|
|
9
|
-
application. You need a feature flag in your project first, either from the dashboard or
|
|
10
|
-
[defined in SDK code](/reference/sdk/features#define-a-feature-flag-in-sdk-code).
|
|
11
|
-
|
|
12
|
-
Which accessor you pick decides *when* the visitor enters the test, so read
|
|
13
|
-
[About feature flag allocation](/explanation/feature-flag-allocation) before you choose.
|
|
14
|
-
|
|
15
|
-
## 1. Choose an accessor
|
|
16
|
-
|
|
17
|
-
Each accessor returns a different value, and they differ in whether a read resolves the
|
|
18
|
-
feature flag. A read that resolves the feature flag commits the visitor to a bucket and reports the
|
|
19
|
-
decision.
|
|
20
|
-
|
|
21
|
-
| API | Returns | Does a read resolve the feature flag? |
|
|
22
|
-
| --- | --- | --- |
|
|
23
|
-
| `useFeature` / `getFeature` | `() => Promise<bucket>` | Only when you call the function that it returns |
|
|
24
|
-
| `useFeatureResult` / `getFeatureResult` | `{ id, bucket }`, and `undefined` until it resolves | Yes, as soon as the component renders |
|
|
25
|
-
| `useFeatureEnabled` / `getFeatureEnabled` | `boolean \| undefined`, the dashboard **Enabled** setting | No |
|
|
26
|
-
| `client.features.listStore` | Every registered feature flag, each with an `isResolved` property | No |
|
|
27
|
-
| `client.features.getById(id)` | A store that holds one feature flag | No |
|
|
28
|
-
|
|
29
|
-
Some decisions must wait for data that you do not have yet, such as a cart, a quote, or
|
|
30
|
-
the profile of a signed-in user. For those, use `useFeature` or `getFeature`. Call the
|
|
31
|
-
function they return after the data arrives.
|
|
32
|
-
|
|
33
|
-
## 2. Read the bucket
|
|
34
|
-
|
|
35
|
-
The bucket is what your site receives. A Boolean feature flag gives `true` or `false`. A
|
|
36
|
-
Text feature flag gives the value of one variant, or `false` for the control group.
|
|
37
|
-
|
|
38
|
-
:::code-group
|
|
39
|
-
|
|
40
|
-
```tsx [React]
|
|
41
|
-
import { useFeatureResult } from '@picked/react/hooks'
|
|
42
|
-
|
|
43
|
-
function MyComponent() {
|
|
44
|
-
// { id, bucket }, or undefined until the feature flag resolves.
|
|
45
|
-
const result = useFeatureResult('hero')
|
|
46
|
-
|
|
47
|
-
return (
|
|
48
|
-
<div>
|
|
49
|
-
{result?.bucket === false && <p>Control</p>}
|
|
50
|
-
{result?.bucket === 'hero-a' && <p>Hero A</p>}
|
|
51
|
-
{result?.bucket === 'hero-b' && <p>Hero B</p>}
|
|
52
|
-
</div>
|
|
53
|
-
)
|
|
54
|
-
}
|
|
55
|
-
```
|
|
56
|
-
|
|
57
|
-
```svelte [Svelte]
|
|
58
|
-
<script lang="ts">
|
|
59
|
-
import { getFeatureResult } from '@picked/svelte/hooks'
|
|
60
|
-
|
|
61
|
-
// A store that holds { id, bucket }, or undefined until the feature flag resolves.
|
|
62
|
-
const result = getFeatureResult('hero')
|
|
63
|
-
</script>
|
|
64
|
-
|
|
65
|
-
{#if $result?.bucket === false}
|
|
66
|
-
<p>Control</p>
|
|
67
|
-
{:else if $result?.bucket === 'hero-a'}
|
|
68
|
-
<p>Hero A</p>
|
|
69
|
-
{:else if $result?.bucket === 'hero-b'}
|
|
70
|
-
<p>Hero B</p>
|
|
71
|
-
{/if}
|
|
72
|
-
```
|
|
73
|
-
|
|
74
|
-
:::
|
|
75
|
-
|
|
76
|
-
:::warning
|
|
77
|
-
`useFeatureResult` and `getFeatureResult` resolve the feature flag as soon as the component
|
|
78
|
-
renders, and they commit the visitor to a bucket at that moment.
|
|
79
|
-
:::
|
|
80
|
-
|
|
81
|
-
:::tip
|
|
82
|
-
Run [type generation](/reference/sdk/type-generation) and `bucket` narrows to the values
|
|
83
|
-
that this Text feature flag declares. Your editor then shows each value, and it reports a
|
|
84
|
-
comparison against a value that the feature flag cannot serve.
|
|
85
|
-
:::
|
|
86
|
-
|
|
87
|
-
## 3. Read it without a framework
|
|
88
|
-
|
|
89
|
-
The event bus works with any framework, and with none:
|
|
90
|
-
|
|
91
|
-
```ts
|
|
92
|
-
import { createClient } from 'picked'
|
|
93
|
-
|
|
94
|
-
const client = createClient({
|
|
95
|
-
/* Put your client options here. */
|
|
96
|
-
})
|
|
97
|
-
|
|
98
|
-
client.eventBus.watch((event) => {
|
|
99
|
-
if (event.type === 'feature_decide' && event.feature.id === 'my-feature') {
|
|
100
|
-
console.log(event.feature) // { id: 'my-feature', key: 'v1', bucket: 'hero-a' }
|
|
101
|
-
}
|
|
102
|
-
})
|
|
103
|
-
```
|
|
104
|
-
|
|
105
|
-
`feature_decide` fires only when the SDK makes a new decision. A visitor who returns
|
|
106
|
-
restores the decision from storage and fires nothing, so watch
|
|
107
|
-
`client.features.listStore` when you need the current state instead.
|
|
108
|
-
|
|
109
|
-
## Related
|
|
110
|
-
|
|
111
|
-
- [About feature flag allocation](/explanation/feature-flag-allocation) — when the
|
|
112
|
-
visitor enters the test.
|
|
113
|
-
- [SDK feature flags](/reference/sdk/features) — the definition shape and the overrides.
|