Preventing line-wraps in URLs?
Is there an option somewhere to change the line-wrap rules? I'd like to prevent wrapping on periods that do not have spaces on one side or the other without disabling line-wrapping entirely.
The issue I'm having is that, when editing HTML templates (e.g. in a Flask app), PyCharm will often wrap lines in the middle of the hostname portion of a URL (at the label separator), resulting in breakage. When it happens it's not hard to find and fix with testing, but I'd prefer to avoid the problem in the first place.
I've tried to have a look through the Editor → Code Style → HTML settings, but nothing looks relevant.
Please sign in to leave a comment.
I don't know of a setting for that, but you could use <!-- @formatter:off --> code <!--@formatter:on -->. Maybe set up a shortcut for it.