javascript moment is not defined code example
Example: moment is not defined
Check if js is included properly
<script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.18.1/moment.min.js"></script>
var back30Days=moment().subtract(30, 'days').format("dddd, MMMM Do YYYY, h:mm:ss p");
console.log('back30Days --> ' + back30Days);