webpack-auto-inject-version/src/components/inject-as-comment/tags.js

12 lines
255 B
JavaScript
Raw Normal View History

2017-04-13 08:40:22 +10:00
import dateFormat from 'dateformat';
import config from 'config';
2017-04-13 08:40:22 +10:00
export default {
version: (context) => {
return context.version;
},
date: () => {
return dateFormat(new Date(), config.componentsOptions.InjectAsComment.dateFormat);
2018-03-15 22:07:22 +11:00
},
2017-04-13 08:40:22 +10:00
};