mirror of
https://github.com/gohugoio/hugo.git
synced 2024-11-29 09:42:05 -05:00
700 B
Executable file
700 B
Executable file
title | linkTitle | description | categories | keywords | menu | weight | signature | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Concat | Concatenating assets | Bundle any number of assets into one resource. |
|
|
90 |
|
Usage
Asset files of the same MIME type can be bundled into one resource using resources.Concat
which takes two arguments, the target path for the created resource bundle and a slice of resource objects to be concatenated.
{{ $plugins := resources.Get "js/plugins.js" }}
{{ $global := resources.Get "js/global.js" }}
{{ $js := slice $plugins $global | resources.Concat "js/bundle.js" }}