Working with dates. I need to get a date on a page before going to FileMaker ( this is an option ). Using the call moment().add( 1, “month”) will give me the result I need , one month from the current date. However the output is full with timestamp. I only need Aug 16, 2020. To get the correct format I can use moment().format(LL). I tried to combine the one function with in the other like FileMaker. I also tried to append the function. Both cases, it returns nothing or invalid date. So my next option is how do I or can I use a variable to do the first calc and use the second calc on the variable. Or what is the proper format in javascript to do one function on another. TIA
You can chain functions eg:
moment( model.dateKey ).add( 1, “month” ) .format( ' ... your format string ...' )
Thanks, I tried that and got no result. I was missing the single ’ ’ around the value.