Javascript get string from an string(with more data) from an JSON

I am currently having an code problem: I get this returned from an JSON:

"data" : "123456789012345 - Placeholder - 1 - anotherplaceholder - this placeholder - 123456789 - lastplaceholder"

As you can see, it returns a long string. Is it possible to do somethin like this:

int number = //code to put the '123456789012345' from above here
const firstplaceholder = //code to put the 'Placeholder' from above here
int number = // code to put the '1' from above here
etc for the other things.

Any idea how I can do this in javascript? Thanks in advance! (if you need more info, let me know, all help is greatly appreciated)

Answer

Like this

/* number = //code to put the '123456789012345' from above here
const firstplaceholder = //code to put the 'Placeholder' from above here
 number = // code to put the '1' from above here
etc for the other things.
*/

const jsonStr = `{"data" : "123456789012345 - Placeholder - 1 - anotherplaceholder - this placeholder - 123456789 - lastplaceholder"}`

const obj = JSON.parse(jsonStr);
const [num1, pl1, num2, pl2, pl3, num3, pl4 ] = obj.data
 .split( ' - ')
 .map(str => isNaN(str) ? str.trim() : +str); // make numbers integers
console.log(num1,num2,num3)