mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-20 22:42:53 -05:00
parent
fdde9f7c5d
commit
a993994d68
1 changed files with 3 additions and 3 deletions
|
@ -2,13 +2,13 @@
|
|||
// Usage: `{{asset "css/screen.css"}}`, `{{asset "css/screen.css" ghost="true"}}`
|
||||
//
|
||||
// Returns the path to the specified asset. The ghost flag outputs the asset path for the Ghost admin
|
||||
var proxy = require('./proxy'),
|
||||
_ = require('lodash'),
|
||||
const proxy = require('./proxy'),
|
||||
get = require('lodash.get'),
|
||||
getAssetUrl = proxy.metaData.getAssetUrl,
|
||||
SafeString = proxy.SafeString;
|
||||
|
||||
module.exports = function asset(path, options) {
|
||||
var hasMinFile = _.get(options, 'hash.hasMinFile');
|
||||
const hasMinFile = get(options, 'hash.hasMinFile');
|
||||
|
||||
return new SafeString(
|
||||
getAssetUrl(path, hasMinFile)
|
||||
|
|
Loading…
Add table
Reference in a new issue