[{"data":1,"prerenderedAt":542},["ShallowReactive",2],{"fougere:post.list:{}":3,"reference:\u002Freference\u002Fpackages\u002Fstate-cookie":6,"reference-pages":323},{"items":4,"hasMore":5},[],false,{"id":7,"title":8,"body":9,"description":315,"extension":316,"file":317,"meta":318,"navigation":142,"path":319,"seo":320,"stem":321,"__hash__":322},"reference\u002Freference\u002Fpackages\u002Fstate-cookie.md","@fougere\u002Fstate-cookie",{"type":10,"value":11,"toc":310},"minimark",[12,16,25,30,104,209,212,221,225,236,268,273,277,284,306],[13,14,8],"h1",{"id":15},"fougerestate-cookie",[17,18,19,20,24],"p",{},"A caller's state kept in a cookie — what ",[21,22,23],"code",{},"state: { cart: { cookie: {} } }"," names, signed by core, carried by every HTTP door.",[26,27,29],"h2",{"id":28},"use-it","Use it",[31,32,36,61,76,90],"code-group",{"className":33,"sync":35},[34],"managers","pm",[37,38,44],"pre",{"className":39,"code":40,"filename":41,"language":42,"meta":43,"style":43},"language-bash shiki shiki-themes material-theme-lighter fougere-pastel material-theme-palenight","npm install @fougere\u002Fstate-cookie\n","npm","bash","",[21,45,46],{"__ignoreMap":43},[47,48,51,54,58],"span",{"class":49,"line":50},"line",1,[47,52,41],{"class":53},"sV8pK",[47,55,57],{"class":56},"sN-8n"," install",[47,59,60],{"class":56}," @fougere\u002Fstate-cookie\n",[37,62,65],{"className":39,"code":63,"filename":64,"language":42,"meta":43,"style":43},"pnpm add @fougere\u002Fstate-cookie\n","pnpm",[21,66,67],{"__ignoreMap":43},[47,68,69,71,74],{"class":49,"line":50},[47,70,64],{"class":53},[47,72,73],{"class":56}," add",[47,75,60],{"class":56},[37,77,80],{"className":39,"code":78,"filename":79,"language":42,"meta":43,"style":43},"bun add @fougere\u002Fstate-cookie\n","bun",[21,81,82],{"__ignoreMap":43},[47,83,84,86,88],{"class":49,"line":50},[47,85,79],{"class":53},[47,87,73],{"class":56},[47,89,60],{"class":56},[37,91,94],{"className":39,"code":92,"filename":93,"language":42,"meta":43,"style":43},"yarn add @fougere\u002Fstate-cookie\n","yarn",[21,95,96],{"__ignoreMap":43},[47,97,98,100,102],{"class":49,"line":50},[47,99,93],{"class":53},[47,101,73],{"class":56},[47,103,60],{"class":56},[37,105,109],{"className":106,"code":107,"language":108,"meta":43,"style":43},"language-ts shiki shiki-themes material-theme-lighter fougere-pastel material-theme-palenight","\u002F\u002F fougere.config.ts\nimport '@fougere\u002Fstate-cookie';\n\nexport default defineFougere({\n  state: { cart: { cookie: {} } },\n});\n","ts",[21,110,111,117,137,144,164,198],{"__ignoreMap":43},[47,112,113],{"class":49,"line":50},[47,114,116],{"class":115},"skXKP","\u002F\u002F fougere.config.ts\n",[47,118,120,124,128,130,133],{"class":49,"line":119},2,[47,121,123],{"class":122},"sK6XW","import",[47,125,127],{"class":126},"sDDC1"," '",[47,129,8],{"class":56},[47,131,132],{"class":126},"'",[47,134,136],{"class":135},"s15xx",";\n",[47,138,140],{"class":49,"line":139},3,[47,141,143],{"emptyLinePlaceholder":142},true,"\n",[47,145,147,150,153,157,161],{"class":49,"line":146},4,[47,148,149],{"class":122},"export",[47,151,152],{"class":122}," default",[47,154,156],{"class":155},"s4mR9"," defineFougere",[47,158,160],{"class":159},"srlTG","(",[47,162,163],{"class":135},"{\n",[47,165,167,171,174,177,180,182,184,187,189,192,195],{"class":49,"line":166},5,[47,168,170],{"class":169},"sHtqg","  state",[47,172,173],{"class":135},":",[47,175,176],{"class":135}," {",[47,178,179],{"class":169}," cart",[47,181,173],{"class":135},[47,183,176],{"class":135},[47,185,186],{"class":169}," cookie",[47,188,173],{"class":135},[47,190,191],{"class":135}," {}",[47,193,194],{"class":135}," }",[47,196,197],{"class":135}," },\n",[47,199,201,204,207],{"class":49,"line":200},6,[47,202,203],{"class":135},"}",[47,205,206],{"class":159},")",[47,208,136],{"class":135},[17,210,211],{},"The import is what makes the word exist: without it, the editor and the boot both refuse it.",[17,213,214,215,220],{},"Every key each one admits: ",[216,217,219],"a",{"href":218},"\u002Freference\u002Fstates","states",".",[26,222,224],{"id":223},"what-it-extends","What it extends",[17,226,227,228,231,232,220],{},"The interfaces of Fougere this package adds its words to, with ",[21,229,230],{},"declare module"," — see ",[216,233,235],{"href":234},"\u002Freference\u002Finterfaces","Interfaces to extend",[237,238,239,252],"table",{},[240,241,242],"thead",{},[243,244,245,249],"tr",{},[246,247,248],"th",{},"interface",[246,250,251],{},"adds",[253,254,255],"tbody",{},[243,256,257,263],{},[258,259,260],"td",{},[21,261,262],{},"FougereStates",[258,264,265],{},[21,266,267],{},"cookie",[17,269,270,271],{},"Entries: ",[21,272,8],{},[26,274,276],{"id":275},"types","Types",[17,278,279,280,283],{},"TypeScript types only — they do not run. Import them with ",[21,281,282],{},"import type"," to type your own code: a variable, a parameter, an option object.",[237,285,286,295],{},[240,287,288],{},[243,289,290,293],{},[246,291,292],{},"name",[246,294],{},[253,296,297],{},[243,298,299,304],{},[258,300,301],{},[21,302,303],{},"CookieOptions",[258,305],{},[307,308,309],"style",{},"html pre.shiki code .sV8pK, html code.shiki .sV8pK{--shiki-light:#E2931D;--shiki-default:#C9B6EA;--shiki-dark:#FFCB6B}html pre.shiki code .sN-8n, html code.shiki .sN-8n{--shiki-light:#91B859;--shiki-default:#EE9F6B;--shiki-dark:#C3E88D}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .skXKP, html code.shiki .skXKP{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#7D8C80;--shiki-default-font-style:inherit;--shiki-dark:#676E95;--shiki-dark-font-style:italic}html pre.shiki code .sK6XW, html code.shiki .sK6XW{--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#8FCF86;--shiki-default-font-style:inherit;--shiki-dark:#89DDFF;--shiki-dark-font-style:italic}html pre.shiki code .sDDC1, html code.shiki .sDDC1{--shiki-light:#39ADB5;--shiki-default:#EE9F6B;--shiki-dark:#89DDFF}html pre.shiki code .s15xx, html code.shiki .s15xx{--shiki-light:#39ADB5;--shiki-default:#A3B0A5;--shiki-dark:#89DDFF}html pre.shiki code .s4mR9, html code.shiki .s4mR9{--shiki-light:#6182B8;--shiki-default:#C9B6EA;--shiki-dark:#82AAFF}html pre.shiki code .srlTG, html code.shiki .srlTG{--shiki-light:#90A4AE;--shiki-default:#A3B0A5;--shiki-dark:#BABED8}html pre.shiki code .sHtqg, html code.shiki .sHtqg{--shiki-light:#E53935;--shiki-default:#93CFC0;--shiki-dark:#F07178}",{"title":43,"searchDepth":119,"depth":119,"links":311},[312,313,314],{"id":28,"depth":119,"text":29},{"id":223,"depth":119,"text":224},{"id":275,"depth":119,"text":276},"A caller's state kept in a cookie — what `state: { cart: { cookie: {} } }` names, signed by core, carried by every HTTP door.","md",null,{},"\u002Freference\u002Fpackages\u002Fstate-cookie",{"title":8,"description":315},"reference\u002Fpackages\u002Fstate-cookie","Ih8GZP1Zw2Ir7BzxDUIp8TOw3dB-s0U0vDItvW9kCKY",[324,329,334,339,344,349,354,358,363,368,371,376,381,386,391,396,401,406,411,416,421,426,431,436,441,446,451,456,461,466,471,476,481,486,491,496,501,506,511,512,517,522,527,532,537],{"path":325,"title":326,"description":327,"stem":328},"\u002Freference\u002Fcli","CLI","fougere new, serve, call, sync, graph — composing a workspace, hosting one frond, invoking an operation from a shell.","reference\u002F01.cli",{"path":330,"title":331,"description":332,"stem":333},"\u002Freference\u002Ferrors","Error codes","Every code an operation can refuse with, and its HTTP status.","reference\u002F02.errors",{"path":335,"title":336,"description":337,"stem":338},"\u002Freference\u002Fconfig","fougere.config.ts","Every key the app config admits, and which package answers each one.","reference\u002F03.config",{"path":340,"title":341,"description":342,"stem":343},"\u002Freference\u002Ffrond-config","frond.config.ts","Every key a frond's own config admits.","reference\u002F04.frond-config",{"path":345,"title":346,"description":347,"stem":348},"\u002Freference\u002Fsources","Source types","Every type an entry of sources: may name, and the keys it admits.","reference\u002F05.sources",{"path":350,"title":351,"description":352,"stem":353},"\u002Freference\u002Fprotocols","Protocols","What protocols: may serve, and what each admits.","reference\u002F06.protocols",{"path":218,"title":355,"description":356,"stem":357},"State keepers","How state: may keep a caller's values.","reference\u002F07.states",{"path":359,"title":360,"description":361,"stem":362},"\u002Freference\u002Fforms","Forms","The types a frond is written with — each one read by the scan.","reference\u002F08.forms",{"path":364,"title":365,"description":366,"stem":367},"\u002Freference\u002Fports","Ports Fougere opens","The classes you stand in front of, or extend, to change what the framework does.","reference\u002F09.ports",{"path":234,"title":235,"description":369,"stem":370},"The empty interfaces a package augments with declare module, and who augments each.","reference\u002F10.interfaces",{"path":372,"title":373,"description":374,"stem":375},"\u002Freference\u002Fdiagnostics","Boot and check diagnostics","Every code a boot, the scan or fougere check can raise, and what it says.","reference\u002F11.diagnostics",{"path":377,"title":378,"description":379,"stem":380},"\u002Freference\u002Fpackages\u002Fadapter-duckdb","@fougere\u002Fadapter-duckdb","Read across an app's sources — one SQL query over what DuckDB can attach.","reference\u002Fpackages\u002Fadapter-duckdb",{"path":382,"title":383,"description":384,"stem":385},"\u002Freference\u002Fpackages\u002Fadapter-env","@fougere\u002Fadapter-env","The process environment as a source — MEILI_URL read as Meili's url, judged at boot.","reference\u002Fpackages\u002Fadapter-env",{"path":387,"title":388,"description":389,"stem":390},"\u002Freference\u002Fpackages\u002Fadapter-file","@fougere\u002Fadapter-file","Rows as files — one JSON or YAML file per row, in a directory per entity.","reference\u002Fpackages\u002Fadapter-file",{"path":392,"title":393,"description":394,"stem":395},"\u002Freference\u002Fpackages\u002Fadapter-graphql","@fougere\u002Fadapter-graphql","Entity → GraphQL types, inputs and CRUD, through Pothos.","reference\u002Fpackages\u002Fadapter-graphql",{"path":397,"title":398,"description":399,"stem":400},"\u002Freference\u002Fpackages\u002Fadapter-memory","@fougere\u002Fadapter-memory","Rows in a Map — the source a first run meets, and the one that ships no driver.","reference\u002Fpackages\u002Fadapter-memory",{"path":402,"title":403,"description":404,"stem":405},"\u002Freference\u002Fpackages\u002Fadapter-rest","@fougere\u002Fadapter-rest","Entity → REST routes.","reference\u002Fpackages\u002Fadapter-rest",{"path":407,"title":408,"description":409,"stem":410},"\u002Freference\u002Fpackages\u002Fadapter-sql","@fougere\u002Fadapter-sql","Entity → SQL tables through Kysely (SQLite, PostgreSQL, MySQL, SQL Server).","reference\u002Fpackages\u002Fadapter-sql",{"path":412,"title":413,"description":414,"stem":415},"\u002Freference\u002Fpackages\u002Fadmin","@fougere\u002Fadmin","A back-office derived from what the app already says it hosts — a react-admin DataProvider over the Fougere wire.","reference\u002Fpackages\u002Fadmin",{"path":417,"title":418,"description":419,"stem":420},"\u002Freference\u002Fpackages\u002Fapp","@fougere\u002Fapp","The host-independent half of a Fougere app: boot, call envelope, REST table, form contract.","reference\u002Fpackages\u002Fapp",{"path":422,"title":423,"description":424,"stem":425},"\u002Freference\u002Fpackages\u002Fauth-better","@fougere\u002Fauth-better","Fougere's auth — a translation layer onto better-auth.","reference\u002Fpackages\u002Fauth-better",{"path":427,"title":428,"description":429,"stem":430},"\u002Freference\u002Fpackages\u002Fcalls","@fougere\u002Fcalls","Optional call log for Fougere: a bounded ring of every dispatch, served as an rpc operation. Read it with `fougere devtools`.","reference\u002Fpackages\u002Fcalls",{"path":432,"title":433,"description":434,"stem":435},"\u002Freference\u002Fpackages\u002Fcli","@fougere\u002Fcli","The Fougere CLI — compose a workspace, serve a frond, call an operation.","reference\u002Fpackages\u002Fcli",{"path":437,"title":438,"description":439,"stem":440},"\u002Freference\u002Fpackages\u002Fcompiler","@fougere\u002Fcompiler","The scan: Fougere reading a project's source to produce the descriptors core boots from. Needs a filesystem and a TypeScript program.","reference\u002Fpackages\u002Fcompiler",{"path":442,"title":443,"description":444,"stem":445},"\u002Freference\u002Fpackages\u002Fcontainer","@fougere\u002Fcontainer","Fougere's DI container: resolution by type, wired from the AST scan. Zero dependencies.","reference\u002Fpackages\u002Fcontainer",{"path":447,"title":448,"description":449,"stem":450},"\u002Freference\u002Fpackages\u002Fcore","@fougere\u002Fcore","The core — scan, call contract, façades, remote stand-ins.","reference\u002Fpackages\u002Fcore",{"path":452,"title":453,"description":454,"stem":455},"\u002Freference\u002Fpackages\u002Fdecorators","@fougere\u002Fdecorators","Configuration sugar (@config) — declarative, never hidden runtime.","reference\u002Fpackages\u002Fdecorators",{"path":457,"title":458,"description":459,"stem":460},"\u002Freference\u002Fpackages\u002Fdefaults","@fougere\u002Fdefaults","The conventional boot of a Fougere app — the one place storage is wired.","reference\u002Fpackages\u002Fdefaults",{"path":462,"title":463,"description":464,"stem":465},"\u002Freference\u002Fpackages\u002Fgraph","@fougere\u002Fgraph","Fougere's graph: a labelled directed multigraph, and the four questions asked of it — order, cycles, components, reach. Zero dependencies.","reference\u002Fpackages\u002Fgraph",{"path":467,"title":468,"description":469,"stem":470},"\u002Freference\u002Fpackages\u002Fhttp","@fougere\u002Fhttp","The words every HTTP door speaks — a method, an answer, the headers a state travels in.","reference\u002Fpackages\u002Fhttp",{"path":472,"title":473,"description":474,"stem":475},"\u002Freference\u002Fpackages\u002Flog","@fougere\u002Flog","Logging for Fougere: two lines for every call, in every process, and a file destination for the lines.","reference\u002Fpackages\u002Flog",{"path":477,"title":478,"description":479,"stem":480},"\u002Freference\u002Fpackages\u002Fnext","@fougere\u002Fnext","The Next.js adapter: mounting, and the one import that is genuinely Next.","reference\u002Fpackages\u002Fnext",{"path":482,"title":483,"description":484,"stem":485},"\u002Freference\u002Fpackages\u002Fnuxt","@fougere\u002Fnuxt","The Nuxt module: Fougere's client primitives and server surface.","reference\u002Fpackages\u002Fnuxt",{"path":487,"title":488,"description":489,"stem":490},"\u002Freference\u002Fpackages\u002Fobservability","@fougere\u002Fobservability","Optional observability for Fougere: one span per operation, W3C Trace Context across any transport.","reference\u002Fpackages\u002Fobservability",{"path":492,"title":493,"description":494,"stem":495},"\u002Freference\u002Fpackages\u002Foclif","@fougere\u002Foclif","A frond's operations, as a terminal: topics, flags and help derived from what it declares.","reference\u002Fpackages\u002Foclif",{"path":497,"title":498,"description":499,"stem":500},"\u002Freference\u002Fpackages\u002Freact","@fougere\u002Freact","Fougere's four primitives as React hooks — host-independent.","reference\u002Fpackages\u002Freact",{"path":502,"title":503,"description":504,"stem":505},"\u002Freference\u002Fpackages\u002Fregistry","@fougere\u002Fregistry","Fougere's registry: one answer per name, refused when a second one arrives, and a reload that says it replaces. Zero dependencies.","reference\u002Fpackages\u002Fregistry",{"path":507,"title":508,"description":509,"stem":510},"\u002Freference\u002Fpackages\u002Fschema","@fougere\u002Fschema","The entity and its 4 axes — shape, role, lifecycle, boundary. Subject-owned judgments, edge-safe.","reference\u002Fpackages\u002Fschema",{"path":319,"title":8,"description":315,"stem":321},{"path":513,"title":514,"description":515,"stem":516},"\u002Freference\u002Fpackages\u002Fstate-session","@fougere\u002Fstate-session","A caller's state kept in a session — what `state: { cart: { session: {} } }` names: one cookie holds a reference, the values a row in a source.","reference\u002Fpackages\u002Fstate-session",{"path":518,"title":519,"description":520,"stem":521},"\u002Freference\u002Fpackages\u002Fsvelte","@fougere\u002Fsvelte","Fougere's four primitives as Svelte stores — host-independent.","reference\u002Fpackages\u002Fsvelte",{"path":523,"title":524,"description":525,"stem":526},"\u002Freference\u002Fpackages\u002Ftesting","@fougere\u002Ftesting","Tests derived from the declaration — cases, stubs and a gradient of realities.","reference\u002Fpackages\u002Ftesting",{"path":528,"title":529,"description":530,"stem":531},"\u002Freference\u002Fpackages\u002Ftransport-http","@fougere\u002Ftransport-http","The call contract on the wire, in JSON-RPC 2.0 (server + client).","reference\u002Fpackages\u002Ftransport-http",{"path":533,"title":534,"description":535,"stem":536},"\u002Freference\u002Fpackages\u002Fvite","@fougere\u002Fvite","The Vite plugin: what any Vite-built host must know to run a Fougere app.","reference\u002Fpackages\u002Fvite",{"path":538,"title":539,"description":540,"stem":541},"\u002Freference\u002Fpackages\u002Fworkflow","@fougere\u002Fworkflow","A release that goes to the end: the journal is three entities, the sweep is an operation, and a shared journal is one line of remotes:.","reference\u002Fpackages\u002Fworkflow",1794396613382]