backdrop / backdrop-issues

Issue tracker for Backdrop core.
144 stars 40 forks source link

[META] Token UI 2.0 #4317

Open klonos opened 4 years ago

klonos commented 4 years ago

There are a couple of D8 core issues related to this which we should be keeping an eye on, such as Add a UI for browsing tokens (looking to introduce a token browser, which is fast/accessible/user-friendly/mobile-friendly), Enable AJAX on-demand loading of sub-trees in the Token help, and also Token UI 2.0.

There's also this contrib module that tries to address the page load time when there are a lot of tokens: https://www.drupal.org/project/fast_token_browser

Fast Token Browser extends the Token module with a faster and more usable interface for browsing and inserting Tokens. It resolves excessive server-side memory usage and client-side unresponsiveness when using the token browser on sites with many tokens. Due to the magnitude of memory savings, this allows the token browser to work with a very low PHP memory limit, even without needing to constrain the maximum token depth.

These improvements are effected by asynchronously loading the token tree. Instead of building and rendering a table containing every token (up to a maximum depth), this module will at most build a single level for a single token at a time, and only when requested. This vastly improves both server- and client-side performance.

yorkshire-pudding commented 2 years ago

@klonos - Fast token browser has now been ported to Backdrop - https://github.com/backdrop-contrib/fast_token_browser