Custom replacement string in censored words and patterns


(Sawood Alam) #1

Currently, all the matching censored words are replaced with a fixed replacement string ■■■■. However, a couple changes might make it more useful.

  1. Allow a global configuration for the censoring character while ■ being the default one. This would be nice for some languages where traditionally a different character is being used, suits well with the typographic style, and available in respected fonts. Additionally, people can have fun by choosing an emoji for the matter.
  2. Allow an optional replacement string for each censoring rule (word or pattern). If not specified, replace characters with the replacement character as it it does now. This could be very useful byproduct of the censoring feature in a way where common misspellings can be corrected. In some languages people make more common spelling mistakes (such as for similar sounding letters). Often literary communities care a lot about correct spellings on their site as it is seen by people and search engines. This could also be helpful in cases where certain brands want certain words be spelled in a specific way, based on their writing style guides (e.g., email vs. e-mail) or local dialect (e.g., color vs colour). It could be helpful in promoting modern spellings of certain words (for example, some two word combinations can be combined with hyphen, but when they become more common they become a single word).

(Rafael dos Santos Silva) #2

This remind me of Blizzard on Overwatch:

If you type

gg ez

the system replaces with

I’m wrestling with some insecurity issues in my life but thank you all for playing with me.