Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Block extension registration #1192
I just noticed that it looks like in v4, extensions get registered like this:
require "middleman-core" require "middleman-sprockets/extension" Middleman::Sprockets.register
Here's the way it worked in v3:
require "middleman-core" require "middleman-syntax/version" ::Middleman::Extensions.register(:syntax) do require "middleman-syntax/extension" ::Middleman::Syntax::SyntaxExtension end
Two reasons I liked block mode:
@tdreyno, what do you think? What are your goals with the changes to extension registration in v4?
Whoops, didn't mean to break compatibility. The method still takes an optional
I think I just thought it was a lot of misdirection to save some dependency requires and it only happens at boot so the perf hit isn't terribly important.
That said, this should remain compatible to let's go back.