@needle-tools/engine
Version:
Needle Engine is a web-based runtime for 3D apps. It runs on your machine for development with great integrations into editors like Unity or Blender - and can be deployed onto any device! It is flexible, extensible and networking and XR are built-in.
29 lines (23 loc) • 1.1 kB
text/typescript
/**
* @internal
*/
export declare type EditorModification = {
guid: string,
propertyName: string,
value: any
}
/** Implement to receive callbacks from {@type @needle-tools/editor-sync} package */
export interface IEditorModification {
/**
* Called when a modification is made through the external editor (called from @needle-tools/editor-sync)
* @param modification The modification that was made in the external editor
* @returns false if you want the editor package to apply the modification. Otherwise it's expected that your code handles applying the change
*/
onEditorModification(modification: EditorModification): void | undefined | boolean;
/** Called immediately after the modification was made through the external editor and applied by the editor-sync package */
onAfterEditorModification?(mod: EditorModification): void;
}
/** @internal */
export function getEditorModificationCache() {
return globalThis["NeedleEditorSync.ModificationCache"] as null | undefined | Map<string, EditorModification>;
}