createElement/getElements, etc. at once, not just a single element — make sure nothing else still depends on these caches before calling it.
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
Clear the Android local cache for Elements. After clearing, previously obtained Element objects can no longer be used.
createElement/getElements, etc. at once, not just a single element — make sure nothing else still depends on these caches before calling it.
static clearElementCache(): void;
clearElementCache() itself, the host environment may still automatically reclaim the cache under memory pressure or similar conditions, so don’t assume the cache is guaranteed to persist. If you only need to release a single element you’re done with, prefer recycleElement or element.recycle() instead, so you don’t affect other elements still in use elsewhere in the plugin.import { PluginCommAPI } from 'sn-plugin-lib';
/**
* Example: clear native Element caches.
*/
export async function exampleClearElementCache() {
PluginCommAPI.clearElementCache();
}