Variable GraffitiPersonalDataConst
GraffitiPersonalData: {
__isFragment?: never;
__isSuspense?: never;
__isTeleport?: never;
new (
...args: any[],
): CreateComponentPublicInstanceWithMixins<
Readonly<
{
autosave?: boolean;
modelValue: {};
name: string;
public?: boolean;
session: GraffitiSession;
},
> & Readonly<{ "onUpdate:modelValue"?: (value: {}) => any }>,
{},
{},
{},
{},
ComponentOptionsMixin,
ComponentOptionsMixin,
{ "update:modelValue": (value: {}) => any },
PublicProps,
{ autosave: boolean; public: boolean },
false,
{},
{},
GlobalComponents,
GlobalDirectives,
string,
{},
any,
ComponentProvideOptions,
{ B: {}; C: {}; D: {}; Defaults: {}; M: {}; P: {} },
Readonly<
{
autosave?: boolean;
modelValue: {};
name: string;
public?: boolean;
session: GraffitiSession;
},
> & Readonly<{ "onUpdate:modelValue"?: (value: {}) => any }>,
{},
{},
{},
{},
{ autosave: boolean; public: boolean },
>;
} & ComponentOptionsBase & VNodeProps & AllowedComponentProps & ComponentCustomProps & new () => {
$slots: {
default(
_: {
isPolling: boolean;
isSaving: boolean;
poll: () => Promise<void>;
save: () => Promise<void>;
},
): any;
};
}
Graffiti Personal Data Vue Component
A Vue component for reading and writing personal information using the Graffiti API. Inspired by the madata Vue component.
The component takes the following props:
v-model
: A two-way binding to the personal data value.name
(string): The name of the personal data to read or write. Similar to a file name: different names refer to different personal data.session
: A Graffiti Session object from a successful login. This component can't be used while logged out.autosave
(boolean, optional): Whether to automatically save changes to the personal data. Default isfalse
.public
(boolean, optional): Whether the personal data is publicly available. Default isfalse
.It exposes the following slots:
save
(()=> PromiseisSaving
(Refpoll
(()=> PromiseisPolling
(RefSee a live example or the example's source code.