I want to remove multiple hashtags from the end of a paragraph.
#abc #def This is a test paragraph. #ads I only want to remove the hashtags after the full stop at the end and keep the hashtag at the center. These hashtags should be removed. #ads #ime #abc
I tried this regular expression /. #([^\]*)/g But it is removing everything from the full stop of the first sentence because the full stop is followed by #ads. How should I remove the hashtags at the end of the paragraph?
I'm using a no-code platform to work. So there are limitations for me to write code. But I'm using the replaceRegex function for doing this.
What I have
var.a = "#abc #def This is a test paragraph. #ads I only want to remove the hashtags after the full stop at the end and keep the hashtag at the center. These hashtags should be removed. #ads #ime #abc"
Function
{{replaceRegex var.a '/\. #([^\\]*)/g' " "}}
Actual Result
#abc #def This is a test paragraph
Expected Result
#abc #def This is a test paragraph. #ads I only want to remove the hashtags after the full stop at the end and keep the hashtag at the center. These hashtags should be removed.