0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-01-20 22:42:53 -05:00
ghost/core/frontend/services/theme-engine
Kevin Ansfield 8a17e723a1 Moved usage of preview options from globalTemplateOptions to localTemplateOptions
refs https://github.com/TryGhost/Team/issues/1097

globalTemplateOptions are supposed to be static with localTemplateOptions being merged in per-request, however the per-request preview data was being extracted and set in the global options. Comments suggest that the global data should be static and eventually updated via other means, the usage of the request object to get per-request preview data is working against that.

- adjusted the preview handler to return an object rather than changing properties by reference on a passed in object
- moved preview data fetching out of `getSiteData()` used in `updateGlobalTemplateOptions()` and into `updateLocalTemplateOptions()` so that we're not relying on the request object in `updateGlobalTemplateOptions()`
2021-09-30 12:12:55 +01:00
..
config
engines Moved theme engines to new theme engine service 2021-04-22 21:05:01 +01:00
handlebars Added beta {{products}} helper for tiers list on post (#13267) 2021-09-10 09:30:41 +05:30
i18n Change to use @tryghost/logging 2021-06-15 15:59:11 +01:00
active.js Removed passing of error to active theme 2021-07-07 14:38:08 +01:00
engine.js
index.js Moved activate from themes to the bridge 2021-04-27 13:52:19 +01:00
middleware.js Moved usage of preview options from globalTemplateOptions to localTemplateOptions 2021-09-30 12:12:55 +01:00
preview.js Moved usage of preview options from globalTemplateOptions to localTemplateOptions 2021-09-30 12:12:55 +01:00