can't believe there is no built-in support for nested layouts. Most websites have cover/landing pages which need another layout, but a lot of html is common (<head>, <script>, ...) Would have been nice to be able to specify a list of layouts to the plug put_layout
I guess I'll have to resort to <%= render "_partial.html" %> or some hacky solution to nest the layout into a base layout
so I coded a module that uses Agent to store some state. I have a start_link function which start Agent.start_link. But when/where should I call this function? I want to use this module as soon as my application starts
josevalim, yeah well, which you talked with about Plug.Static this morning. I try to make it all make sense, :static_url config, :url config, static_url/2 and static_path/2 route helpers, options in Plug.Static (:at path, :from path), and I can't reason with all this :D
however static_path/2 makes use of a configurable :path parameter, which I could set to an absolute url pointing to a CDN if I decide to switch from local storage to a CDN
josevalim, yeah I will go for the simplest solution. I just wanted to serve them from a different configurable location to distinguish them well from regular assets, but I add complexity for nothing.