Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Make script source locator mechanism pluggable [SPR-5106] #9779
Currently ScriptFactoryPostProcessor's convertToScriptSource method allows only inline or Resource-based scripts. Suggest that ScriptFactoryPostProcessor should allow the script locator mechanism to be pluggable and allow scripts to be loaded from anywhere.
Something along the lines of extracting the convertToScriptSource() method in ScriptFactoryPostProcessor into a pluggable strategy, with perhaps a default if you don't want to do anything more than inline or Resource-based scripts. So maybe there would be a ScriptLocator interface which you could plug into the ScriptFactoryPostProcessor rather than needing to subclass SFPP and override the protected convertToScriptSource method, which I did to allow scripts to be loaded from a database.
7 votes, 8 watchers