Regex not working on wrapped app (BDK)

I’m facing an issue where I’m extracting names from a string returned from an API call using regex, which works absolutely fine on desktop and the mobile version of the app viewed on desktop, however when viewed in the BDK wrapped version of the app, the extracted names do not appear. Has anyone experienced this before?

The string is structured, like so:
PALMER, David Peter Richard

To extract the Surname before the comma: /^[^,]+/
To extract the Names after the comma: /(?<=,)[^,]+/

Any insights appreciated, thanks

Hello @tyrelsmythe

I don’t see any reason to have different results since BDK or Jasonelle uses the same engines in Chrome or Safari. Are you getting the same result on iOS and Android?

Hey @JohnMark, yeah it seems quite strange… And yes, on both iOS and Android only the text that being extracted with the regex is not show, rest of the elements from the api appear fine. At first I was using capture groups in the regex but then changed that when i realised it’s not supported by bubble, but still no luck. Thanks for the input

That’s what I thought too. You have to break the search in half to find out which expression is not working.

@JohnMark It’s the strangest thing… So i got some updated regex that seems to work individually for each parts of the string, but when i place the two elements with their respective regex patterns applied in the repeating group cell (one for the first names and the other for the surname), only one of them renders in the wrapped mobile app. Fine on desktop and the mobile screen viewed on desktop but in the wrapped version broken…

The updated regex is:
^[^,]+ for the first part
(?<=, ).* for the second part.

1 Like

This isn’t as strange as it might seem. In fact it has recently been discussed here: Help! My App Went Viral And There's A Big Bug - #17 by Clasicwebtools

The problem is that regex is supported differently by different browsers. The lookbehind (the second part) isn’t supported in safari.

1 Like

Why do you use regex? You can use split by to achieve same results?

Split by , should give you a list of items.


I agree with @nocodeventure , a split by comma would work and then you pass the items.

Problem with the first regex is the lookbehind expression (?<=). Look-behinds are too resource-consuming, I think it is the reason why they are not supported in JS


The last one you shared (“(?<=, ).*”) marks the same issue:

With this you will match everything after the comma:

1 Like

Interesting… thanks for the info! Been banging my head on this for the last week. Using :split by as suggested below by @nocodeventure and it’s working perfectly. Appreciate your input

1 Like

Works a treat. Thanks so much for the info… literally been driving me mad for a week. Thanks for coming to the rescue!

Split by worked perfectly… never going to forget that one haha. Thanks for the additional infor re. the regex, i’ll save this for future use! Cheers