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

144
Views
React axios ReactJS AXIOS post doesn't work

console error -> [1]: https://i.stack.imgur.com/xOfUV.png

   axios
      .post("https://bootcamp-2022.devtest.ge/api/application", {
token: "7e475dfc-0daa-4108-81c8-d6c62a3df4ca",
first_name: JSON.parse(localStorage.getItem("PersonalInfo").first_name),
last_name: JSON.parse(localStorage.getItem("PersonalInfo").last_name),
email: JSON.parse(localStorage.getItem("PersonalInfo").email),
skills: JSON.parse(localStorage.getItem("techskill").skills),
work_preference: JSON.parse(
localStorage.getItem("covid").work_preference),


.then((res) => console.log(res))
      .catch((err) => {
        console.log(err);
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

As the error metioned you have an error on your json

This is your current code

first_name: JSON.parse(localStorage.getItem("PersonalInfo").first_name)

This is how it should be

first_name: JSON.parse(localStorage.getItem("PersonalInfo")).first_name

And you might want to hide the api and the token .

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!