blipson89 / Synthesis

Synthesis is a universal object mapper for Sitecore
MIT License
75 stars 25 forks source link

Regeneration of the model via event handler #37

Closed kamsar closed 7 years ago

kamsar commented 7 years ago

For development, it would be quite handy to have the option to enable an item:saved event handler that, when a template or field item was saved, queued a regeneration of the Synthesis model.

The queue should be rolling async (e.g. templates tend to fire lots of saves in rapid succession, we need to debounce the event - waiting 1-2 seconds before going is probably a good idea.

Also should have it disabled by default, since it should never go to prod where the model files won't - or shouldn't - exist to get updated.

kamsar commented 7 years ago

Done in https://github.com/kamsar/Synthesis/commit/dfd6ce31f5edc02d7db4bc8ee8dea0c4ee5da061

kamsar commented 7 years ago

Fixed in 8.2.2