Skip to content

Added option cache_templates to keep compiled template in memory (for Rails integration)#46

Merged
fterrazzoni merged 1 commit into
masterfrom
railscache
Sep 3, 2017
Merged

Added option cache_templates to keep compiled template in memory (for Rails integration)#46
fterrazzoni merged 1 commit into
masterfrom
railscache

Conversation

@fterrazzoni
Copy link
Copy Markdown
Contributor

@fterrazzoni fterrazzoni commented Sep 3, 2017

::Babl.configure do |config|
    config.cache_templates = true # Default is false
end

If this option is enabled, BABL's Rails integration keeps all compiled templates in a cache forever. It noticeably improves performances, and this difference will become much more significant when code generation will be available.

Notice that only Rails integration is impacted by this setting. There is no other caching mechanism in BABL anywhere else.

@fterrazzoni fterrazzoni merged commit cc52b32 into master Sep 3, 2017
@fterrazzoni fterrazzoni deleted the railscache branch September 3, 2017 15:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant