DEV Community

Discussion on: Formatting Code for DEV Comments and Posts

Collapse
 
chidioguejiofor profile image
Chidiebere Ogujeiofor • Edited

Is three a way I can make a text to wrap to new line. I find that my readers have to scroll when I show some code examples. For instance:


...

schema_pattern = "^(feat|fix|chore|perf|refactor)(\\([A-Za-z0-9\\-]{1,}\\)){0,1}: [A-Za-z][\\S ]{1,}\n\n((- [A-Za-z][\\S ]+\n)*\n){0,1}(closes ticket#\\d+)\\s*$"

...



Enter fullscreen mode Exit fullscreen mode

Is there a way I can prevent the scroll, here?