I will have a string like below
var str = "-#A
This text belongs to A.
Dummy Text of A.
-#B
This text belongs to B.
Dummy Text of B.
-#C
This text belongs to C.
Dummy text of C.
-#Garbage
This string should be ignored"
I want an array like below ignoring text heading with "Garbage"
var arr = [["A","This text belongs to A.
Dummy Text of A."],["B","This text belongs to B.
Dummy Text of B."] etc...]
Please help me on this. How can I make it done...