Skip to content

Instantly share code, notes, and snippets.

@adamrosloniec
Last active July 17, 2019 22:50
Show Gist options
  • Save adamrosloniec/3ba3a2921466a7037bbf7e4299615aa9 to your computer and use it in GitHub Desktop.
Save adamrosloniec/3ba3a2921466a7037bbf7e4299615aa9 to your computer and use it in GitHub Desktop.
Regex - Polish Language with some (soft) special characters
var dataOld = ...;
var dataNew = dataOld.replace(/[^0123456789aąbcćdeęfghijklłmnńoópqrsśtuvwxyzźżAĄBCĆDEĘFGHIJKLŁMNŃOÓPQRSŚTUVWXYZŹŻ\ \!\"\#\$\%\&\'\(\)\+\,\.\/\:\;\<\=\>\?\@\[\]\_\`\{\|\}\–\—\‘\’\‚\“\”\„\…\-]/g, '');
return dataNew;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment