You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
88250
changed the title
清理未引用资源时,文档块也支持忽略custom-data-assets和data-assets属性定义的资源文件
Ignore assets associated with the custom-data-assets block attribute when cleaning unreferenced assets
Sep 24, 2024
---Original---
From: "Jeffrey ***@***.***>
Date: Wed, Sep 25, 2024 07:40 AM
To: ***@***.***>;
Cc: ***@***.******@***.***>;
Subject: Re: [siyuan-note/siyuan] Ignore assets associated with the`custom-data-assets` block attribute when cleaning unreferenced assets (Issue#12574)
@88250 这个应不应该算 Development ?感觉只有插件开发者需要关心
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you were mentioned.Message ID: ***@***.***>
清理未引用资源时,文档块也支持忽略custom-data-assets和data-assets属性定义的资源文件
In what scenarios do you need this feature?
开发插件的时候,有一些数据是文档相关的,和文档强绑定的,所以有这个需求,目前看源码,只有widget类型的块支持上述俩属性:

Describe the optimal solution
更改应该很简单 ,全局搜索只有这俩处适配custom-data-assets和data-assets属性。可惜我不会go。

有一点需要注意,custom-data-assets和data-assets的设计可能要优化一下:因为过往这俩忽略属性只在widget块生效,所以一般不会有其它的插件或者挂件占用。
但是一旦文档块要加上这俩忽略属性的话,可能会有不同的插件都需要使用这个属性,这个时候,设计成忽略所有以custom-data-assets和data-assets开头的属性的资源内容更合理。
比如custom-data-assets-xxx1,custom-data-assets-xxx2都应该被正确处理。
Describe the candidate solution
No response
Other information
No response
The text was updated successfully, but these errors were encountered: