Class: Pakyow::Assets::Framework

Inherits:
Object
  • Object
show all
Defined in:
lib/pakyow/assets/framework.rb

Instance Method Summary collapse

Instance Method Details

#bootObject



22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# File 'lib/pakyow/assets/framework.rb', line 22

def boot
  object.class_eval do
    # Let other frameworks load their own assets.
    #
    stateful :asset, Asset

    # Let other frameworks load their own asset packs.
    #
    stateful :pack, Pack

    include Application::Config::Assets
    include Application::Behavior::Assets
    include Application::Behavior::Assets::Packs
    include Application::Behavior::Assets::Silencing
    include Application::Behavior::Assets::Externals
    include Application::Behavior::Assets::Watching
    include Application::Behavior::Assets::Prelaunching
    include Application::Behavior::Assets::Processing

    after "load" do
      isolated(:Renderer) do
        # Load this one later, in case other actions define components that will load assets.
        #
        include Presenter::Renderer::Behavior::Assets::InstallAssets
      end
    end
  end
end