Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

207
Views
How to get simple date (“Month Number”)?

Im trying to get the date, but im wanting to to return ex ”Oct 29”. Ive tryed using split, but it changes everyday. Heres what I have so far.

Let date = Date().split(“ 2021”)[0];

This returns day<string> month day<int>

about 4 years ago · Juan Pablo Isaza
2 answers
Answer question

0

You can format it there are various inbuilt methods or do this:

Let date = Date().toString().substring(4,10);
about 4 years ago · Juan Pablo Isaza Report

0

You can use the toLocaleString function to achieve what you want. This code below will generate the output you wanted ("Oct 29").

let date = new Date().toLocaleString('en-US', { month: 'short', day: 'numeric' });
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!