In a Rails app, I have this current Regex validator below:
validates :characters, format: {with: /\A(([a-z0-9])+(-?[a-z0-9]+)*\s?)+\Z/, message: "can't be blank. Characters can only be [a-z 0-9 . # - +]" }
My validation for Characters initially only allowed lowercase letters and digits. Now I would like to allow for extra characters . # - + how do I structure my Regex now?
-as well as an optional space.########is also valid?