shift73k/assets_old/node_modules/svg-sprite-loader/lib/utils/interpolate.js

16 lines
433 B
JavaScript
Raw Normal View History

const { interpolateName } = require('loader-utils');
/**
* @param {string} pattern
* @param {Object} options
* @param {string} options.resourcePath
* @param {string} [options.context]
* @param {string} [options.content]
*/
function interpolate(pattern, options) {
const { resourcePath, context, content } = options;
return interpolateName({ resourcePath }, pattern, { context, content });
}
module.exports = interpolate;