PageSourceSearch

https://fluidframework.com/assets/js/0c925d40.400ca6ac.js

js fluidframework.com collected 2026-10-02 04:35:14 UTC 4,888 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunkfluid_framework_website=self.webpackChunkfluid_framework_website||[]).push([[2062],{571663:(e,r,a)=>{a.r(r),a.d(r,{assets:()=>d,contentTitle:()=>s,default:()=>p,frontMatter:()=>i,metadata:()=>t,toc:()=>l});const t=JSON.parse('{"id":"api/fluid-framework/arraynodedeltaop-typealias","title":"ArrayNodeDeltaOp TypeAlias","description":"A single operation in an array node change delta. Used to efficiently sync an external representation of an array (e.g. a text editor or virtual list) with tree changes without needing to snapshot the old state or diff the entire array. Each op describes a contiguous run of positions in the array before the change. For inserts, read the new element values from the current tree at those positions.","source":"@site/docs/api/fluid-framework/arraynodedeltaop-typealias.md","sourceDirName":"api/fluid-framework","slug":"/api/fluid-framework/arraynodedeltaop-typealias","permalink":"/docs/api/fluid-framework/arraynodedeltaop-typealias","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"ArrayNodeDeltaOp TypeAlias","sidebar_label":"ArrayNodeDeltaOp","displayed_sidebar":"docsSidebar"},"sidebar":"docsSidebar","previous":{"title":"ArrayNodeCustomizableSchemaUnsafe","permalink":"/docs/api/fluid-framework/arraynodecustomizableschemaunsafe-interface"},"next":{"title":"ArrayNodeInsertOp","permalink":"/docs/api/fluid-framework/arraynodeinsertop-interface"}}');var n=a(886070),o=a(403793);const i={title:"ArrayNodeDeltaOp TypeAlias",sidebar_label:"ArrayNodeDeltaOp",displayed_sidebar:"docsSidebar"},s=void 0,d={},l=[];function c(e){const r={a:"a",admonition:"admonition",code:"code",h2:"h2",p:"p",pre:"pre",...(0,o.R)(),...e.components};return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(r.p,{children:"A single operation in an array node change delta. Used to efficiently sync an external representation of an array (e.g. a text editor or virtual list) with tree changes without needing to snapshot the old state or diff the entire array. Each op describes a contiguous run of positions in the array before the change. For inserts, read the new element values from the current tree at those positions."}),"\n",(0,n.jsxs)(r.admonition,{title:"This API is provided as an alpha preview and may change without notice.",type:"warning",children:[(0,n.jsxs)(r.p,{children:["To use, import via ",(0,n.jsx)(r.code,{children:"fluid-framework/alpha"}),"."]}),(0,n.jsxs)(r.p,{children:["For more information about our API support guarantees, see ",(0,n.jsx)(r.a,{href:"https://fluidframework.com/docs/build/releases-and-apitags/#api-support-levels",children:"here"}),"."]})]}),"\n",(0,n.jsx)(r.admonition,{title:"Sealed",type:"info",children:(0,n.jsx)(r.p,{children:'This type is "sealed," meaning that code outside of the library defining it should not implement or extend it. Future versions of this type may add members or make typing of readonly members more specific.'})}),"\n",(0,n.jsx)(r.h2,{id:"arraynodedeltaop-signature",children:"Signature"}),"\n",(0,n.jsx)(r.pre,{children:(0,n.jsx)(r.code,{className:"language-typescript",children:"/** @sealed */\nexport type ArrayNodeDeltaOp = ArrayNodeRetainOp | ArrayNodeInsertOp | ArrayNodeRemoveOp;\n"})}),"\n",(0,n.jsx)(r.h2,{id:"arraynodedeltaop-remarks",children:"Remarks"}),"\n",(0,n.jsxs)(r.p,{children:["There is no dedicated ",(0,n.jsx)(r.code,{children:'"move"'})," op. Moves are represented as ",(0,n.jsx)(r.code,{children:'"remove"'})," + ",(0,n.jsx)(r.code,{children:'"insert"'}),". When an element is moved within the same array it appears as a ",(0,n.jsx)(r.code,{children:'"remove"'})," at the source position followed by an ",(0,n.jsx)(r.code,{children:'"insert"'})," at the destination position. When an element is moved across two different arrays, the source array's delta contains a ",(0,n.jsx)(r.code,{children:'"remove"'})," and the destination array's delta contains an ",(0,n.jsx)(r.code,{children:'"insert"'})," \u2014 they cannot be correlated without additional bookkeeping on the caller's side."]}),"\n",(0,n.jsxs)(r.p,{children:["The operations cover the complete array: trailing elements that were not changed are included in a final ",(0,n.jsx)(r.code,{children:'"retain"'})," op. Applying every operation therefore consumes the entire pre-edit array and produces the entire post-edit array."]})]})}function p(e={}){const{wrapper:r}={...(0,o.R)(),...e.components};return r?(0,n.jsx)(r,{...e,children:(0,n.jsx)(c,{...e})}):c(e)}},403793:(e,r,a)=>{a.d(r,{R:()=>i,x:()=>s});var t=a(830758);const n={},o=t.createContext(n);function i(e){const r=t.useContext(o);return t.useMemo((function(){return"function"==typeof e?e(r):{...r,...e}}),[r,e])}function s(e){let r;return r=e.disableParentContext?"function"==typeof e.components?e.components(n):e.components||n:i(e.components),t.createElement(o.Provider,{value:r},e.children)}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.